Reputation: 43
I have mutiple rows of data which correspond to different companies and I need to be able to change the report based of the company title. However I have these rating averages by Month that I want to be able to put into a line chart but I can't seem to figure out how to it. This is what the data looks like:
Ideally I want the line chart to look something like this:
Upvotes: 0
Views: 1567
Reputation: 718
You need to pivot the data to look like this:
|Company |Period |Value |
-------------------------------
|CompA |January |10000 |
|CompB |January |99999 |
|CompA |February |88888 |
etc...
You can do this in the 'Edit queries' section 'PowerQuery'
Assuming a dataset that looks like this:
Bring it in to PowerBI and Select All the Month Columns ( Shift/ctrl + Click ):
Then hit 'unpivot columns' under the transform tab:
Then I would add a 'column from examples' to switch Jan in to 1 and Feb in to 2 and march in to 3, etc...:
Finally, dump it into a chart and slicer:
Remember to set the value to average:
Upvotes: 1