Forum Discussion
categories in one chart
Hi,
I have customer list with digital usage per year, so I have separated them based on if condition to create three separate column as mobile, web, both . now I have to get a bar chart shows the number of users in this three categories. I tried a couple of ways but for some reasons it always gives me weird results.
Is there a work around for this type.
MaliniBaktha the best way to handle this is to unpivot your data:
- transform data
- select customer column table
- Right-click, unpivot other columns It will add two columns, attribute, and value, Rename these as per your requirement
- Close and apply
To visualize, add attribute column on x-axis and value column on y-axis/values.
2 Replies
- parry2k
Super User
MaliniBaktha the best way to handle this is to unpivot your data:
- transform data
- select customer column table
- Right-click, unpivot other columns It will add two columns, attribute, and value, Rename these as per your requirement
- Close and apply
To visualize, add attribute column on x-axis and value column on y-axis/values. - foodd
Community Champion
Please provide your work-in-progress Power BI Desktop file (with sensitive information removed) that covers your issue or question completely in a usable format (not as a screenshot).
https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216
Please show the expected outcome based on the sample data you provided.
https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...
This allows members of the Forum to assess the state of the model, report layer, relationships, and any DAX applied.