Year on Year, Quarter on Quarter change in Salary

Sandeep Warrier

Well-known Member
Joined
Oct 31, 2008
Messages
2,680
Hi All,

I have employee-wise salary data that I get every quarter. At a summary level, I need to compare the change in salary as of end of last fiscal year. For us, the fiscal year ends in March, so until next year June, all quarter data will be compared with current year March data.

Quarter EndEIDSalary
3/31/202212772
3/31/202222849
3/31/202232105
3/31/202242462
3/31/202252673
3/31/202262102
3/31/202272068
6/30/202212772
6/30/202222849
6/30/202232105
6/30/202242462
6/30/202272068
6/30/202282180
6/30/202292985
6/30/2022102321
6/30/2022112511
6/30/2022122819

Here is a sample subset of the data. There are other employee identifiers like pay band, business unit etc., that I have not added here.

I created a calculated column called concat and concatenated EID and Quarter End Date. I then created a column called Baseline Salary, which will give me March salary and use the following formula -

Power Query:
Baseline Salary =
var OrignalBase = LOOKUPVALUE(Compensation[Salary],Compensation[Concat],Compensation[EID]&"@"&EOMONTH(EDATE(Compensation[Quarter End],IF(MONTH(Compensation[Quarter End])=12,-9,IF(MONTH(Compensation[Quarter End])=9,-6,IF(MONTH(Compensation[Quarter End])=6,-3,-12)))),0))
var FirstAvailSal = LOOKUPVALUE(Compensation[Salary],Compensation[Concat],Compensation[EID]&"@"&CALCULATE(MIN(Compensation[Quarter End]),ALLEXCEPT(Compensation,Compensation[EID])))
return IF(ISBLANK(OrignalBase),FirstAvailSal,OrignalBase)

And then I have a measure
Power Query:
YoY Incr = DIVIDE(AVERAGE(Compensation[Salary])-AVERAGE(Compensation[Baseline Salary]),AVERAGE(Compensation[Baseline Salary]))

However, when I pulled YoY Incr into a visual, I realised that it was not considering the true salary of March 2022, but was considering the salaries of all employees the are active in June 2022. For example, in the sample data above, the average salary for march would be 2433, but when I look at YoY in June, it considered only 2451.2 (EID 5 and 6 are not available in June data).

I then tried to create a new summary table using the SUMMARIZE function, but when I use the SUMMARIZE function in the visual, it started to give me very weird data and all dates between the quarters even though they don't exist in the table.

Using the table given above, I expect the following

Quarter EndYoY Increase
3/31/20220%
6/30/20223.05%

AVG(March) = 2433, AVG(June) = 2507.2, (June - March)/March = 3.05%

Would appreciate guidance on solving this.

Also posted at
Re: Year on Year, Quarter on Quarter change in Salary

Regards,
Sandeep
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN

Forum statistics

Threads
1,223,903
Messages
6,175,284
Members
452,630
Latest member
OdubiYouth

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top