Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Showing running totals in an Area chart instead of individual transactions?

So I have the following chart:

 

 

It's based on a table that contains (sample values):

 

Date | Type | Value

1/1/19 | Income | 5.60

1/2/19 | Expense | 10.95

 

What I'd like to see is that instead of showing each individual transaction, it shows the growing totals. So over time the red area gets larger and larger, as does the green area. Eventually the green hopefully overtakes the red.

 

Is there any way to set this graph to show the running totals instead of the individual transactions?

 

1 ACCEPTED SOLUTION
v-lid-msft
Community Support
Community Support

Hi @Anonymous ,

 

We can use a measure in area chart to achieve your requirement:

 

Measure =
SUMX (
    FILTER (
        ALLSELECTED ( 'Table' ),
        [Date] <= SELECTEDVALUE ( 'Table'[Date] )
            && 'Table'[type] = SELECTEDVALUE ( 'Table'[type] )
    ),
    [Value]
)

14.PNG

 

 

 

BTW, pbix as attached.

 

Best regards,

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-lid-msft
Community Support
Community Support

Hi @Anonymous ,

 

We can use a measure in area chart to achieve your requirement:

 

Measure =
SUMX (
    FILTER (
        ALLSELECTED ( 'Table' ),
        [Date] <= SELECTEDVALUE ( 'Table'[Date] )
            && 'Table'[type] = SELECTEDVALUE ( 'Table'[type] )
    ),
    [Value]
)

14.PNG

 

 

 

BTW, pbix as attached.

 

Best regards,

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Community Support Team _ Dong Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Thank you all!

Ashish_Mathur
Super User
Super User

Hi,

Create a Calendar Table and build a relationship from the Date column of your Data Table to the Date column of your Calendar Table.  In the Calendar Table, extract the Year by using this calculated column formula

Year = Year(Calendar[Date])

Month = FORMAT(Calendar[Date],"mmmm")

Create a slicer and drag Year from the Calendar Table to that slicer.  Select 2019 in the Year slicer.  To your visual, drag Month and Date from the Calendar Table to the x-axis.  Write these measures

Total = SUM(Data[Value])

YTD Total = CALCULATE([Total],DATESYTD(Calendar[Date]))

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

Right-click on your column or table and click on Add Quick Measure. Choose running total option and create a new running total measure 

Screenshot 2019-09-28 15.35.39.pngScreenshot 2019-09-28 15.36.02.png

Anonymous
Not applicable

Thanks for the reply, I appear to be doing something wrong though, the graph is unchanged and this is the table of that measure:

 

2019-09-28_11-58-04.png

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.