How can I create the calculated field for this visual?

I am creating a visualization for this excel sheet data. The columns are names of programs and the rows represent occurrences for if that program has a control. The controls are the rows going down. A sample of this spreadsheet is attached to this post.

1 represents yes and 0 represents no.

I need to calculate the percentages of 1s (yes) for each program and then I want to visualize this. Every time I write a function I get an error and have no idea what the error is. I have also done simple sum and avg functions and nothing is working. If anyone can help this would be greatly appreciated

Hello @miauy , welcome to the QuickSight community!

Can you share the functions that you have tried and the errors that you got from QuickSight?

Hello, I figured out the syntax error I had, so my information is now displaying, but on my chart is there a way I can rename this 1 to another name? Or am I unable to since its directly from my data?

Hey @miauy

That is coming from your data and part of the “Data Label” of the visual so you won’t be able to change it. You could create a calculated field using ifelse to change the 1/0 to “Yes”/“No” or you could remove the data label and create a custom legend (legends in quicksight have pretty limited editability unfortunately).

For a custom legend you would create a text box and format the text to match your data colors in your target visual.

Thank you for your help!

1 Like