Forum Discussion
Modify vizualisation
Hello,
Im new in Power BI and im wondering 2 things for my visualization.
First, how to use value instead of percentage (axis y) ?
Second how can i make the first visualization to look like the second visualization ? I dont know how to put the names (ghassen, nathalie and marcel) and the month on axis x
to
- Anonymous2 years ago
Hi AudreyRene ,
For percent stacked bar charts, modifying the Y-axis to a numeric value would be odd, as it would not accurately reflect the size of the values under each category.
1. It is recommended that you use stacked bars and create a measure like:Measure = VAR __denominator = CALCULATE( SUM( 'financials'[Profit] ), ALLEXCEPT( 'financials','financials'[Product] ) ) VAR __numerator = SUM('financials'[Profit]) VAR __rate = FORMAT(DIVIDE(__numerator,__denominator),"Percent") RETURN __rateAnd apply it to the data label's value format:
2. You can put [Names], [Month Name] on the x-axis.Then you need to create a conditional format to display different colors according to [Names].
Measure 2 = SWITCH( SELECTEDVALUE('financials'[Country]), "Canada","Red", "France","Blue", "Germany","Yellow" )Output:
Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
- Anonymous2 years ago
Hi AudreyRene ,
Try using a clustered bar chart and placing [name] in the value of Legend.Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
3 Replies
- AnonymousNot applicable
Hi AudreyRene ,
For percent stacked bar charts, modifying the Y-axis to a numeric value would be odd, as it would not accurately reflect the size of the values under each category.
1. It is recommended that you use stacked bars and create a measure like:Measure = VAR __denominator = CALCULATE( SUM( 'financials'[Profit] ), ALLEXCEPT( 'financials','financials'[Product] ) ) VAR __numerator = SUM('financials'[Profit]) VAR __rate = FORMAT(DIVIDE(__numerator,__denominator),"Percent") RETURN __rateAnd apply it to the data label's value format:
2. You can put [Names], [Month Name] on the x-axis.Then you need to create a conditional format to display different colors according to [Names].
Measure 2 = SWITCH( SELECTEDVALUE('financials'[Country]), "Canada","Red", "France","Blue", "Germany","Yellow" )Output:
Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
- AudreyReneHelper I
Hello,
First, Thank You ! The first solution works. For the second, i understand your example, but i dont know how to make it with my data
I need to have this visualization.
Axis x = Regroup by month of each year
Secondary Axis x = Regroup by the name of the person who make the transaction
Axis y = Number of transaction
- AnonymousNot applicable
Hi AudreyRene ,
Try using a clustered bar chart and placing [name] in the value of Legend.Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group