Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
I have some data in columns as seen below:
I need this data to appear in a visual like this:
I can't figure out how to make the column headers as rows and then get multiple values from these columns, such as average, count and sum. I have only been able to get a single value like average:
Help, please!
Hi @IBrant ,
Please try:
1. unpivot these colunms in powerqery:
2. Group by [Attribute]:
If you want create a matrix visual, please select these and unpivot
Best Regards,
Gao
Community Support Team
If 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
Hi, Gao,
I forgot to mention that these are columns that are calculated based on date columns. So in Power Query the original columns are all dates. I added new columns in table view and wrote formulas to figure out the number of days between the dates and that is how I got those columns. I apologize, I'm a relatively new Power BI user.
Hi @IBrant ,
Try selecting the matrix. --> format pane -> Value --> switch values to the row --> row headers --> turn off stepped layout:
Output:
Is this your expected output?
Best Regards,
Gao
Community Support Team
If 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
Hi, Gao,
Thanks for your response but I need it to look more like this:
Also, I do not have a row column that inclues all of the categories like your country column. TIA
@IBrant , You need to create calculation groups, you have option in model view to create calculation groups
Create three calculation items and use measures for each of columns. use the Expression function to use data from the line level
Avg = AVERAGEX(Table,SELECTEDMEASURE())
Count = COUNTX(Table,SELECTEDMEASURE())
Sum = Sumx(Table,SELECTEDMEASURE())
I used these two measure and test
Qty Line = Sum(Sales[Qty])
Gross Line = sum(Sales[Gross Sales])
Model explorer public preview with calculation group authoring| Measure Slicer: https://youtu.be/VfxfJJ0RzvU
This sounds great, but I don't have a calculation group option.
Check out the October 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
113 | |
108 | |
108 | |
92 | |
67 |
User | Count |
---|---|
167 | |
130 | |
129 | |
94 | |
91 |