Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello
I want to add several variables to a bar chart. The variables contain values that are between 0 and 10, and I want the chart show the mean of each variable.
The label of each bar must be the name of the variable or a custom value, and the value must be the average of the values of that varibale.
For example, I have two variables, satisfaction and knowledge, with 300 cases each. And the values they contain are between 0 and 10.
I need a chart that contains two bars, with the mean of each variable and the labels of the bars being the variable title or custom text.
Can it be done?
Thank you.
Solved! Go to Solution.
Hi @josegovia,
Suppose your source table looks like:
You can use a clustered column chart to show the average values for satisfaction and knowledge. But the limitation is that it is not possible to show the label as the name of the variable or a custom value, data labels can only show the numeric values for each bar.
As a workaround, you can unpivot the table structure first in query editor mode. Select the [Case type] column, then from Transform menu tab, choose 'Unpivot other columns' from the drop down list 'Pivot Column'. Then, you will get a table as below.
Best regards,
Yuliana Gu
Hi @josegovia,
To keep the original table structure, you can replicate a new table, then, you can unpivot columns based on this new table.
Best regards,
Yuliana Gu
Hi @josegovia,
Suppose your source table looks like:
You can use a clustered column chart to show the average values for satisfaction and knowledge. But the limitation is that it is not possible to show the label as the name of the variable or a custom value, data labels can only show the numeric values for each bar.
As a workaround, you can unpivot the table structure first in query editor mode. Select the [Case type] column, then from Transform menu tab, choose 'Unpivot other columns' from the drop down list 'Pivot Column'. Then, you will get a table as below.
Best regards,
Yuliana Gu
Hi,
This is the same problem I'm facing. I can't select "Averge of Value". My only two options are "Count" or "Distinct Count" or to create a new quick measure.
Is the average option in the orinigal post no longer available?
Thanks so much!
Thanks for the solution.
But three things happen to me:
Can you help me with these three questions?
Thank you very much.
José
Well, I've already solved the first one. I have changed the format of the varibal to "Whole Number".
But I need help with the other two.
Thank you.
Hi @josegovia,
To keep the original table structure, you can replicate a new table, then, you can unpivot columns based on this new table.
Best regards,
Yuliana Gu
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
98 | |
78 | |
66 | |
53 |
User | Count |
---|---|
144 | |
104 | |
100 | |
86 | |
64 |