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
NickT
New Member

Subtracting two rows in Power BI

I have sales data, cost data and hence margin data for two different periods.

 

Period        Volume         Sales          Cost of sales     Margin   Unit selling price  Unit cost    Unit margin

Qtr1             50,000      £100,000       £60,000           £40,000             £2                   £1.20            £0.80 

Qtr2             80,000      £120,000       £80,000           £40,000             £1.50              £1.00            £0.50

  

I want to calulate the difference between the two data sets so I can explain the margin movement between the two periods.

I want to automate the explanation for the volume variance, price variance and cost variance

 

Once I have explained the movement between volume, sales price and cost I want to slice on the data to slice it further by sales region, product category, salesman etc.

 

Any advice would be very much appreciated.

 

Kind regards

 

NickT 

 

3 REPLIES 3
Anonymous
Not applicable

Not sure how would like to present. Could you please explain the expected output.

 

Thanks
Raj

Hi Raj

 

What I am looking to achieve is a waterfall chart as follows:

 

Opening % margin

 

Volume variance

 

Price variance

 

Cost variance

 

Closing % margin

 

I then want to then slice this graph by sales region, portfolio category, sales channel etc. to interrogate the data further.

 

The interrogation will be carried out by a series of slicers set against the base data in the waterfall chart.

 

In the background I will have a data tab with the supporting backing data.

 

I hope this helps.

 

Kind regards

 

Nick

Volume period 1Volume period 2Gross price period 1Gross price period 2Discount period 1Discount period 2Cost period 1Cost period 2Net price period 1Net price period 2Margin period 1Margin period 2Gross price per unit period 1Gross price per unit period 2Discount per unit period 1Discount per unit period 2Net Price per unit period 1Net Price per unit period 2Unit margin period 1Unit margin period 2Cost per unit period 1Cost per unit period 2Period 1 margin %Period 2 magin %Volume differenceDiscount differencePrice diferenceCost differenceCheckVolume difference %Discount difference %Price difference %Cost difference %% Check
5060£1,000.00£1,100.00£100.00£130.00800825£900.00£970.00£100.00£145.00£20.00£18.33£2.00£2.17£18.00£16.17£2.00£2.42£16.00£13.7511%15%£20.00-£10.00-£100.00£135.00£0.002%-1%-9%12%4%
                                  
        Gross price less discountNet price less costGross price divided by volumeDiscount divided by volumeNet price divided by volumeMargin divided by volumeCost divided by volumeMargin divided by net priceDifference in volume times unit margin period 1Difference in unit discount times period 2 volumeDifference in unit price times period 2 volumeDifference in unit cost times period 2 volume Volume difference / margin movement times margin % changeDiscount difference / margin movement times margin % changePrice difference / margin movement times margin % changeCost difference / margin movement times margin % change 

I AM TRYING TO REPLICATE TEH ABOVE CALCULATIONS IN POWER BI

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.