Can Power BI add range selection to a Line Chart? - powerbi

I'd like to build a report with power BI line chart. For there are too many values on the X-Axis, I was trying to add a range selection on the X-Axis like what amChart does.
So, I'm wondering if power BI can do this.
Also, I want to add hyperlink to each value on the X-Axis to link to related shared folder, is it doable?

For time range selection, take a look at https://app.powerbi.com/visuals and try the Advanced Time Slicer visual. It might already do what you're looking for.
For the x-axis urls, you have several approaches you can try. The easiest approach is to have a related table in your report that shows the links. Then when a user selects a datapoint in your line chart, the table would update to show the relevant links. Alternately you might try to extend the Power BI line chart with your own logic. This might be hard since Cartesian charts are more complex than other charts. You can find the line chart code here: https://github.com/Microsoft/PowerBI-visuals/blob/master/src/Clients/Visuals/cartesian/lineChart.ts
Alternately you can just write your own purpose built visual that does exactly what you want. This might actually be easier than extending the Power BI chart. You can learn how to build your own visual by looking at our wiki: https://github.com/Microsoft/PowerBI-visuals/wiki
I was thinking about this more and wanted to mention one more solution. If you're looking to show the 'last n days' of data, instead of an arbitrary range, you can add a measure in DAX that returns the last days. I have an example here: http://blogs.msdn.com/b/lukaszp/archive/2015/08/08/finding-the-latest-date-in-power-bi-desktop.aspx

Related

How to forecast in Power BI using DAX

I have a chart in excel I wish to replicate in PBI.
My Excel chart is a bar chart dated axis with 2 series, running up march, but with data only up until now.
Each bar series has a trendline, which forecasts a trend up to the end of the financial year.
In power BI I have tried to replicate, but I cannot seem to add 'forecast' from the analytics tab unless my chart is a line graph.
So I now have 2 line series in a chart like so:
I have added trendline to both but there is no option to add the forecast line unless I only have 1 data series.
As I've removed a series I can now toggle on the forecast line in the analytics tab.
So I now have 1 line series in my line graph like so:
I actually need to have the data and the corresponding forecast for both data series, so I would have series 1 & 2 plotted like above, on the same graph together.
Is there a way to do this on the analytics tab??
If not, how should I go about it? I was thinking I could use DAX to forecast until March 2023 instead and then drag the line into the line graph and format it to dashed?
Thanks
Here is some sample data step by step for what i'm looking for (very simple thing to do in excel!):
This is the same data, pivoted with the 2 series mapped out on a line graph, and trendline added for each:
I just want to be able to show a trendline extending and forecasting forward, past the months I already have like I have done in Excel.
Yeah i think here your best solution would be to use the "what if" parameter in Dax to get the result you need
For a forecasting line to be performed on a line chart, Below requirements should be met. Otherwise You can't see this option on the analytics tab:
You need to change your datasets, and datatypes accordingly.
The last one is especially valid for you, because there is not a one-day period between your data values, in fact monthly organized.

Power BI - How to have a calculated column and place it in a merged cell?

I am new to Power BI and with the limited time given, I am stuck at how to come up with:
Below Table B-Row1 ("1/20" and "M"-Monday cell) - how to
specifically place the date measures in their specific cell and put
it in one column?
How can I merge the cells under the Total column?
How to add all the numbers from the Type1 and Type2 columns and place it in the merged cell in #2?
Any clues/direction/links on how to achieve the Target Table B below will be much appreciated.
PS. Below Table A. Current is just using Matrix Visualization in Power BI.
You can't exactly do what you are after. PowerBI allows you to rapidly put amazing visuals together however that comes at the price of lack of (easy) flexibility. You could build your own custom visual or look in App Source for a visual that does this, or build the Visual in some other tool (via custom code).
However, I'd recommend sticking with the PowerBI matrix, which will give you a cascading drill down and work out how best to align your data to it and other out of the box visuals. Once you start to delve in to convoluted work-arounds to give users data in exactly the format they request you start to burn a lot of time. Look for alternatives to tell the data's story and work with your end-user to buy in to it.
Just wanna share that I have resolved my problem not using one type of visualization, but through using 3 different visualizations in Power BI. I used:
1 Table visual for Date column
1 Table visual for Total column
1 Matrix visual for the Code+Type mapping and counts
I also used DAX function to get the Date format and another DAX function used for both Total and Code+Type counts(to filter data according to the specified date).
Thanks for the response, #Murray and #RADO.

How to add multiple fields in columns of Power BI matrix and view them without drilldown

I've trying out Power BI to solve some visualization problem in my organization and I've been working on desktop version of Power BI to try out its features.
I'm stuck at few issues and cannot find our way out of this.This is a sample view I've been trying to create:
Figure 1:
1
We've a dataset containing Product Opinion across gender, Age Group, Geography etc. and we want to pivot the opinion across different parameters as shown above.But when we use Matrix view of Power BI and add two parameters in columns, it creates a drill down view as shown below:
Figure 2: 2
On adding multiple fields in the column section we get an option to move down to next hierarchy as shown below:
Figure 3:3
Although we have the option to move down to hierarchy ,we are unable to show then side by side as we've shown in Figure 1.
Is there a way we can get the visualization as given in Figure 1 ?
Also, Currently the columns and rows are automatically sorted alphabetically. Is there a way we can adjust the column and row position as per our needs?
To sort the rows in a custom order, you will have to create an index table. The below link walks you through the steps involved:
http://www.excelnaccess.com/custom-sorting-in-power-bi/
Now, to achieve the visualization you are looking for, the only way I can think of is to create two matrix visualizations (One for gender and other for age group) and place them in such a way, that it gives the illusion of the same table. There might be a better way to do this, but I these workarounds work just fine. Hope this helps.

Plain Report in PowerBI report similar to repeatable section in Cognos

I'm new to Power BI but am not seeing something that I feel should be pretty common report functionality. I have a cognos report that has a list grouped by specific fields, each item in the list has fields, etc. Each "item" is repeated in the list.
Can Power BI do something similar to this functionality? I have been looking at multi-row cards, tables, etc. but I'm not seeing a repeater control or something that would allow to mimic this functionality? The multi-row cards would work but I can't style them how the customer wants or needs b/c they are printed and need to match a certain format.
Even the single cards, if I could drop all the fields I need as single cards, format them how I want. Is there a way to have all rows repeated in a "list/set" of those single cards? Right now when I drop a bunch of single cards and a splicer it displays the first record and that is it? Surely there is a way to get all the records.
Here is an example (I need the formatting to remain basically the same, each row from data source represents one page that looks like this)
Thanks,
Tim
I don't think this is possible in Power BI yet. A muti-row card has similar functionality, but is not customizable enough to match what you are trying to do. Custom formatting is one of the drawbacks of Power BI at this time.
You can vote for this idea on the Power BI Ideas site, but I'm guessing it's not a high priority for Microsoft for now.

How to build a matrix, similar to the table from Google analytics

In PowerBI I'd like to build Non-standard matrix very similar to the report in Google Analytics.
What do I have now:
I want to change my subtotal to measure, which is calculated as the difference in percentage of the two values
What I want to get:
In Power BI, there is no way to override the subtotals of a matrix with a calculation. Part of the challenge is that you know there are only two date ranges, but as far as Power BI is concerned, there could be any number of date ranges.
It's difficult to tell from your question exactly what input you have and what output you're looking for. Further, the numbers in your screenshots are obscured. However, one consideration would be to solve the problem using measures (i.e. a measure representing the first date range, a measure representing the 2nd date range, and then a measure calculating the difference between them). You may need to change the layout of your visual a little to make this work and the specific design would depend on how static your date ranges are.