I'm trying to match the value in an array and return the median value found in the fourth column of an array in another sheet B_Sheet!B1:B65404
Since Vlookup only returns the first value I tried using Index and Match but not sure why it failed.
Tried this but didnt work ARRAYFORMULA(IFERROR(MEDIAN(FILTER(INDEX(B_Sheet!D1:D65404,MATCH(B5:B36518,B_Sheet!B1:B65404,0)),LEN(INDEX(B_Sheet!D1:D65404,MATCH(B5:B36518,B_Sheet!B1:B65404,0)))>0)),""))
For reference, this Vlookup did work:
ARRAYFORMULA(IFERROR(VLOOKUP(B5:B36518,B_Sheet!B1:E65404, 4, FALSE),""))
Example1: With formula in top of second column of Sheet1
Name | Array Return Median value |
---|---|
James | 5 (formula is here) |
Robert | 6 |
And looking up in the next sheet.... :
B_Sheet!
Name | Test Scores |
---|---|
James | 3 |
Robert | 4 |
James | 5 |
Robert | 6 |
James | 7 |
Robert | 8 |