Help needed with Finding which quartile does an employee lie in.

Joined
Apr 6, 2023
Messages
9
Office Version
  1. 2021
Platform
  1. Windows
Hi there, I need some help! I have two datasets:

First dataset and I need help with calculating the last column i.e. the cohort ranking:

NameJob TitleLocationTotal Hours workedCohort Ranking
AAnalystLondon10
BAssociate Milan20
CAnalystLondon40

Second dataset:

Job Title Location 1st quartile2nd quartile 3rd quartile 4th quartile
AnalystLondon10203040
Associate Milan5101520

My question:
In the first table last column (Cohort Ranking), how do I calculate that for Employee A, based on the job title, location and total hours worked, they fall in X quartile?

So for example for Employee A it should say 1st quartile, Employee B should say 4th quartile and so on.

Can you please help me? Thank you!
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
OK, couple of slight errors in your formula.

Change:
Rich (BB code):
=IFERROR(XLOOKUP(U4, FILTER('Hours Analysis by Cohort'!$E$4:$J$39, ('Hours Analysis by Cohort'!$D$4:$D$39=Output!F4)*('Hours Analysis by Cohort'!$B$4:$B39=Output!D4)*('Hours Analysis by Cohort'!$C$4:$C$39=Output!E4), ""), 'Hours Analysis by Cohort'!$G$3:$J$3), "")

To:
Rich (BB code):
=IFERROR(XLOOKUP(U4, FILTER('Hours Analysis by Cohort'!$G$4:$J$39, ('Hours Analysis by Cohort'!$D$4:$D$39=Output!F4)*('Hours Analysis by Cohort'!$B$4:$B$39=Output!D4)*('Hours Analysis by Cohort'!$C$4:$C$39=Output!E4), ""), 'Hours Analysis by Cohort'!$G$3:$J$3), "")

and copy down column V. It doesn't pick up a quartile for every case, because not all cases match all conditions.
 
Upvote 0
OK, couple of slight errors in your formula.

Change:
Rich (BB code):
=IFERROR(XLOOKUP(U4, FILTER('Hours Analysis by Cohort'!$E$4:$J$39, ('Hours Analysis by Cohort'!$D$4:$D$39=Output!F4)*('Hours Analysis by Cohort'!$B$4:$B39=Output!D4)*('Hours Analysis by Cohort'!$C$4:$C$39=Output!E4), ""), 'Hours Analysis by Cohort'!$G$3:$J$3), "")

To:
Rich (BB code):
=IFERROR(XLOOKUP(U4, FILTER('Hours Analysis by Cohort'!$G$4:$J$39, ('Hours Analysis by Cohort'!$D$4:$D$39=Output!F4)*('Hours Analysis by Cohort'!$B$4:$B$39=Output!D4)*('Hours Analysis by Cohort'!$C$4:$C$39=Output!E4), ""), 'Hours Analysis by Cohort'!$G$3:$J$3), "")

and copy down column V. It doesn't pick up a quartile for every case, because not all cases match all conditions.
Thank you! This is amazing. I really appreciate it
 
Upvote 0

Forum statistics

Threads
1,224,816
Messages
6,181,138
Members
453,021
Latest member
Justyna P

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