cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
kolovez
Helper I
Helper I

Calculate difference between Min. & Max

Hi all,

 

I have a dataset that shows orderlines per row. Similar to this table:

Item no.

RevenueQuantitySales Price Column
Item110110
Item12438

 

I am trying to create a visual table that shows Min. Max, Avg Price and the dif. between Min & Max.

kolovez_1-1626952287620.png

 

 

Question / Help Request:

I can easily create the Min. Max and Avg. Sales Price, but I can't create the formula for dif. between Min. and Max.? anyone can help?

It needs to evaluate the row with the minimum sales price for a specific item and compare it to the same item just on the row with highest sales price.

Dif. between Min. Max = "Maximum Sales Price - the Minimum Sales Price" 

 

 

I already have the Sales Price Column, so i just use the inbuilt function for Min. and Max Sales Price:

kolovez_0-1626952128075.png

For the Avg. Sales Price i use this calculation:

 

Avg. Sales Price = SUM(InitiativeMonitor_table[Turnover (DKK)])/SUM(InitiativeMonitor_table[Qty])

 

 

 

1 ACCEPTED SOLUTION
kolovez
Helper I
Helper I

just figured out it was utterly simple. haha

 

Min. SP = MIN(InitiativeMonitor_table[Sales Price DKK column])
Max SP = MAX(InitiativeMonitor_table[Sales Price DKK column])
Min. Max SP dif. = [Max SP]-[Min. SP]

View solution in original post

1 REPLY 1
kolovez
Helper I
Helper I

just figured out it was utterly simple. haha

 

Min. SP = MIN(InitiativeMonitor_table[Sales Price DKK column])
Max SP = MAX(InitiativeMonitor_table[Sales Price DKK column])
Min. Max SP dif. = [Max SP]-[Min. SP]

View solution in original post

Helpful resources

Announcements
Power BI December 2021 Update_carousel 768x460.jpg

Check it Out!

Click here to read more about the December 2021 Updates!

Jan 2022 Dev Camp 768x460 copy.png

Power BI Dev Camp- January 27th, 2022

Mark your calendars and join us for our next Power BI Dev Camp!

UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Top Solution Authors
Top Kudoed Authors