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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
Burtoninlondon
Frequent Visitor

How can I obtain the minimum value from my measure

Hello,

 

I have a dashboard in which I want to determine the difference from a high water mark of running totals form a set of values.

 

Burtoninlondon_0-1720945231990.png

 

I have three measures:

 

1. Running Total, this calculates the running total of the values in date order.

 

Running Total = 
CALCULATE (
    SUM(Data[Value]),
    FILTER ( ALLSELECTED(Data), Data[Index] <= MAX ( Data[Index] ) )
)

 

 

2. High Water Mark, this calculates the highest value the Running Total has reached so far.

 

High Water Mark = 
MAXX (
    ADDCOLUMNS (
        FILTER ( ALLSELECTED( 'Data' ), Data[Index] <= MAX ( Data[Index] ) ),
        "Running Total", [Running Total]
    ),
    [Running Total]
)

 

 

3. Difference from High Water Mark, this calculates the difference between the High Water Mark and the Running Total.

 

Difference from High Water Mark = [Running Total] - [High Water Mark]

 

 

I want to be able to capture the minimum value of the Difference from High Water Mark which would be -226 but I am unable to do so as the MIN() function cannot be used against a measure.

 

Can anyone help me on how I can obtain this minimum value?

 

MY PBIX file can be downloaded from this wetransfer link...PBIX file 

 

Any help you can offer is appreciated.

 

Kind regards,

 

Neil 

1 ACCEPTED SOLUTION
ThxAlot
Super User
Super User

ThxAlot_0-1720951715419.png



Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



View solution in original post

4 REPLIES 4
ThxAlot
Super User
Super User

ThxAlot_0-1720951715419.png



Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



@ThxAlot,

 

I appreciate the help and the resolution of my problem.

 

Neil

tharunkumarRTK
Super User
Super User

@Burtoninlondon 

You can follow the below syntax 

Screenshot 2024-07-14 at 2.19.29 PM.png

 

You can find the file here

Please find the other formula where I calculated the min value till the current row.



Need Power BI consultation, hire me on UpWork .


If the post helps please give a thumbs up



If it solves your issue, please accept it as the solution to help the other members find it more quickly.




Tharun



@tharunkumarRTK, thanks for your response, it was very helpful.

 

I'm going to mark the other response from @ThxAlot as the solution as it needed less measures in my model.

 

Neil

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

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

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.