Sparklines KPI

by Mary-Leena Tchenkoue

Sometimes we may want to have more than just a BAN for KPIs but also a trendline/sparkline of the KPI. As an example, I show how to create a sparkline KPI for Sales using sample Superstore data.

Put continuous quarter of Order Date to columns and Sales to rows. Now we want to show the total sales as KPI in the same sheet. If we drop Sales as SUM([Sales]) on the marks card and add this to the title we will get a range of values. This is because it considers the Sales of all the marks in the view, from min to max. What we need a fixed calculation of the total sales.

Drop this field on the marks card and add it to the title. Format it the way you will do in a BAN or KPI sheet. Next, reduce the size of the visualization to get that sparkline. Simply drag the edges from right to left and from top to bottom to get something like this.

Add this sheet to your dashboard and you get a nice KPI with a sparkline.

Additional tip: right now if the cohort analysis sheet was to be used as filter, clicking a bar will modify the line chart of the Sales KPI sheet but the TOTAL SALES will remain the same. To fix this, after you have selected a sheet as filter and clicked on a point or bar to apply the action to oher sheets, go now to your KPI sheet. In the filter card make the add the filter Action to context. Now the filter will also change the value of your KPI and not just the sparkline.

Wed 01 Jun 2022

Mon 30 May 2022

Tue 31 May 2022