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.
I have these two columns in the report- I want Pie chart based on count of the rows of months column where months value is between 1-2 then3 and 6,6-10 and rest more than 10. And showing sum of dollar value in the pie chart in their respective region.
Cost | Months |
$481,948 | 8 |
$399,263 | 25 |
$295,784 | 36 |
$229,014 | 25 |
$191,070 | 8 |
$188,109 | 8 |
$147,928 | 4 |
$136,728 | 2 |
$106,519 | 5 |
$102,782 | 10 |
$77,583 | 5 |
$92,820 | 7 |
$82,212 | 6 |
$76,248 | 9 |
$68,529 | 3 |
$71,543 | 34 |
$53,061 | 4 |
$49,058 | 6 |
$25,054 | 42 |
$19,115 | 12 |
$20,128 | 2 |
$21,550 | 20 |
Hi @learner03
You can add a calculated column with below DAX in the original table, then use it to create a pie chart like below. Is this what you want? "Sum of Cost" will display in the pop-up tooltip once the mouse cursor hovers over a sector.
Month Group =
SWITCH(TRUE(),
'Table'[Months]<=2, "1-2",
'Table'[Months]<=6, "3-6",
'Table'[Months]<=10, "7-10",
"> 10"
)
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Hi @v-jingzhang Can I do this in some way using a measure because my stock cover and Cost is a measure and not a direct column in the table?
Hi @learner03
I'm not sure without knowing how the data is like. Can you provide some sample data in table format and the DAX formula of those measures? And which fields do you want to place into the pie chart?
BR,
Jing
@learner03 , are you looking for count bucketing?
Dynamic Segmentation Bucketing Binning
https://community.powerbi.com/t5/Quick-Measures-Gallery/Dynamic-Segmentation-Bucketing-Binning/m-p/1...
Dynamic Segmentation, Bucketing or Binning: https://youtu.be/CuczXPj0N-k
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 |
---|---|
114 | |
99 | |
83 | |
70 | |
60 |
User | Count |
---|---|
150 | |
115 | |
104 | |
89 | |
65 |