How to Create a Cumulative Line Chart in Power BI?

Creating a cumulative line chart in Power BI involves first selecting the desired data and adding it to a line chart visual. Then, the cumulative option must be selected from the formatting options to display the running total of the data. Additional formatting options such as axis labels and legend can be customized to enhance the visual. This type of chart is useful for tracking changes over time and identifying trends and patterns in the data.


Often you may want to create a line chart in Power BI that shows the cumulative values of some variable over time.

The following step-by-step example shows how to create the following cumulative line chart in Power BI:

Power BI cumulative line chart

Let’s jump in!

Example: How to Create a Cumulative Line Chart in Power BI

Suppose we have the following table in Power BI named my_data that contains information about sales made on various dates by some company:

Suppose we would like to create a line chart that displays the cumulative sales over time.

Before we can create the line chart, we must add a new column that contains the cumulative sum of the values in the Sales column.

To do so, click the Table tools tab along the top ribbon, then click the New column icon:

Then type the following formula into the formula bar:

Cumulative Sales = 
CALCULATE (
    SUM ( 'my_data'[Sales] ),
    ALL ( 'my_data' ),
    'my_data'[Date] <= EARLIER ( 'my_data'[Date] )
)

This will create a new column named Cumulative Sales that contains the cumulative sum of the values in the Sales column:

To create a line chart that displays the values in the Cumulative Sales column, click the Report View icon on the left hand side of the screen:

An empty line chart will be inserted:

Next, drag the Date variable under the X-axis label, then drag the Cumulative Sales variable under the Y-axis label:

This will produce the following line chart:

Power BI cumulative line chart

The x-axis displays the date and the y-axis displays the cumulative sales.

Additional Resources

The following tutorials explain how to perform other common tasks in Power BI:

x