use-sparkline-power-bi

The Quickest & Easiest Way to use SPARKLINE in POWER BI

Sparkline in Power BI has been a long-demanding feature in Power BI. I first heard about sparkline a few years back when I was attending corporate training on Tibco Spotfire.

Sparkline is a tiny chart that helps to analyze the trend for each row as it is placed in each cell of the column in a table/matrix. It can be used to see seasonal increases or decreases in the values, economic cycle, etc.

Now, finally, Microsoft has launched the Sparkline feature in Power BI that allows you to add single or multiple sparklines in the table/matrix visual in Power BI. It is important to know that the Sparkline feature in Power BI is a Public Preview feature so it can be tested and used for development purposes.

Currently, Microsoft Power BI supports 5 sparklines per visual and 52 points per sparkline. Also, when sparkline is ON for a visual, then the visual can have a maximum of 20 columns. It has been defined by default by Microsoft itself for performance optimization.

Are you new to Power BI? Looking for the best free resources to learn Power BI. Please check the article “Ultimate Guide of Microsoft PowerBI Tutorials: Step by Step Approach”

Turn On the Sparkline Public Preview Feature

In order to use the Sparkline feature, first, you will have to enable it in the preview feature option. You can follow File > Options and settings > Options > Preview features, and select Sparklines.

Add Sparkline to Table/Matrix

Once you have enabled the Sparkline Preview Feature.

  1. Create Table/Matrix.
  2. In the Visualization Pane, right-click on the measure that you have used in the table/matrix, and you will see the option “Add a Sparkline”. Just select it.
add-sparkline-power-bi
  1. Once you click on the “Add to Sparkline” option, you will get the option to select the X axis dimension and summarization type and the Y axis will be selected default which you can change as per your requirement. On the X axis, you can select the date column present in the table/matrix in order to show a trend in the sparkline.
add-sparkline-settings
  1. Click on the Create button.
table-with-sparkline

Edit the Sparkline

We will see various options available in the Power BI for editing the sparkline in the table/matrix visual.

  1. You can change the default line chart to a column chart by editing the sparkline in the format tab in the Visualization Pane. Also, you can change the color and width of the sparkline chart. Option 1 in the below visual can be used to change the chart type to Column and option 2 can be used to change the color of the sparkline chart.
sparkline-chart-change
  1. You can add the marker to the sparkline chart and also adjust the marker settings in the format tab of the visualization pane. You can change the scenario when to show the marker, color, and type.
sparkline-marker-properties

Consideration and Limitation

  1. Visuals with Sparkline can not be pinned to the dashboard.
  2. Microsoft Power BI supports 5 sparklines per visual and 52 data points per sparkline and for performance reasons, only 20 columns are allowed in the visual having sparkline.
  3. Sparkline is supported in Azure Analysis Service but not supported in On-Premise Analysis Service.

Similar Posts

Leave a Reply

Your email address will not be published.