After reading this thread on the official forums I still didn't see how to plot columns without aggregation, and that thread did not offer any working solution.
Is there a way in MS Power BI Desktop to simply plot one or more columns without any aggregation?
Imagine I just have a simple table, imported from csv, that has numerical values in two columns, and I want to plot those individual values in a scatter plot, which is one of the most elementary tasks possible and is simply done e.g. in Excel.
Is this not possible in Power BI Desktop?
To my surprise, this was certainly not trivial...
The only solution / workaround I found so far feels hacky, and probably doesn't scale up for too many datapoints. But here it is nonetheless.
For simple, small, whole-number datasets...
Suppose this dataset:
X;Y
1;2
1;2
1;4
3;4
4;1
1;2
4;1
2;1
Import that CSV and add a calculated column:
Label = "(" & [X] & ";" & [Y] & ")"
Now create the scatter plot with:
Legend set to Label
X Axis set to Average of X
Y Axis set to Average of Y
And you'll get this:
Not optimal, but at least it's a start for smaller datasets.
For simple, small, fractional number datasets...
The same process as above, and it'll look like this:
The legend is starting to break down and is probably best removed.
For larger datasets...
Suppose you have an Excel sheet with two columns X and Y, both with the formula =RAND() * 5. Copy paste this row to e.g. 500 rows, so you have many data points.
Load it up in PowerBI. Add the Label column like above. Add a scatter plot and drag Label to Details, and set X and Y to their respective axis. Here's the result:
It works pretty decently, I guess.
Related
I currently have a report that kind of looks like this in Excel. Is it possible to create the same structure with the color formatting in Power BI? Especially with the Percentage Sale and Sales Amount below each other in the row?
I tried using Matrix visual but I kind of run into a problem since the columns would have different format types - whole number and percentage. Also tried with showing columns in rows, while using Percentage Sale and Sales Amount as two columns. But then I would have problems with the color formatting. Any ideas how to achieve it in Power BI?
Its actually simple ..... just follow these steps
1.) You can use matrix or table both... but I preferred tables
2.) Go to format Visual (In visualistation you can see 3 option... its the middle one)
3.) After that click on values.
4.) Now you can se background color , alterante background color etc
5.) Just choose it acc to preferences
If you want a bar label in a selected column then,
6.)In build format, right click on your column (which you want to customize)
7.)Select conditional formatting
8.)Now you can change color
9.)apply this. After that you can see your data of selected columns are showing grid bars
Team,
I'm trying to format individual cells within a Power BI matrix table. It wouldn't be a conditional formatting because it's not based on the values of the cell, rather it's based on the intersection of my X and Y labels.
The first image is my starting matrix table and the second image is how i'd like to format the cells.
I believe you are looking for the Table Heatmap visual. it is for free. Tick the 3 dots and click "Get more visuals".
I would like to create a simple chart from 2 or more columns in Power BI.
Here's my data, for each column, a 1 marks an occurrence of an event, null means it did not happen.
I would like to turn this data into a very simple bar graph, showing both these fields' numeric totals (i.e. summing all the 1's). The bars would be shown side by side. I would like it to look exactly like this, only instead of male/female it would show "alcohol occurrences" and "MDMA" occurrences.
Here's my stacked column chart:
And when I try and put the column names on the axes so that they can be properly labeled, I get this:
I can achieve most of what I want using a clustered bar chart, but the problem there is that it won't let me label the axis with the alcohol / MDMA column names:
How can I make a simple, labeled graph, stacking both columns up against each other, showing the numeric sums for each column? Again, I want it to look exactly as the male/female example shown above. Is this even possible? Thank you in advance.
In the above scenario, all the values are considered to be in the same category and that means there is no direct way to do this. There are a couple of workarounds to make it look like the desired output:
To get the gap between the two bars:
You should create a new measure, Measure New = 0
Add this measure in the middle of the two values in the bar chart
This should give you a gap in between the two bars
To get the axis values added:
Create two text boxes with the text "Alcohol" and "MDMA" added
Place these text boxes below the respective bars to make it look like they are the axis values
These workarounds can become quite tedious when you have to do it for a larger number of charts/values. On a lighter note, it baffles me that you can consistently come up with these specific scenarios where you expect the charts to do exactly the opposite of what they are meant for 😉
I am new to PowerBI so sorry in advance. I would like to reproduce the plot below (created in Tableau) in PowerBI.
I need the two plots to be sorted by the values of the first one.
In PowerBI I can generate two such plots, but I do not manage to use the values of the first plot to sort the second one.
How can I do that?
Plot with an x-axis that is shared by two bar chart plots
Is there a way to display multiple charts on the same image using Google Charts api?
To elaborate:
I have one data series which I want to display as bar chart.
I have another data set which has nothing to do with the first one (well they are correlated but the values are hundred times bigger).
X-axis is for dates.
I want to have second data set displayed as line chart with Y-axis on the left.
I found something similar in "Compound charts" section but as far as I understand markers are calculated based on already displayed data set - and I want to have them independent.
In other words - is it possible to make image like this:
http://chart.apis.google.com/chart?cht=bvg&chm=D,0033FF,1,0,5,1&chs=200x150&chd=t1:30,10,20|60,40,50&chxt=y
but with the line being independent and their values axis being on the right.
I'm sorry I'm not familiar with the terminology - I'm sure there is a name for what I'm trying to achieve.
Thanks!
Only 2 years behind the curve but just to let you know that I have achieved your objective of displaying 2 datasets (one a bar chart, the other a line chart) against 2 different axis scales.
The devil is in the scaling parameter &chds and explicit axis values using &chxr. Essentially, I defined the explicit scales for the x-axis, y-axis and r-axis. and then instructed the scaling parameter to scale each dataset differently.
So for an r dataset between 0 - 10 and a y dataset between 0-2 I would write;
&chds=0,2,0,10 (y then r defined in my axis parameter, i.e. &chxt=y,r)
...and...
&chxr=0,0,2|1,0,10
Let me know if you need more detail!
I've looked into something similar to this before and have used the google chart API a lot. I'm 90% sure the answer is no. Sry :(
Yep it is possible.
Here is an example of two datasets displayed on the same axes. 1 is a bar chart the other is a line graph....
This line - chd=t1:95,1,1,3,10,3,77|95,52,44,24,11,2,1 - allows for the two datasets.
slothistype