Forum Discussion

Derharm1's avatar
Derharm1
Copper Contributor
Dec 13, 2023
Solved

Dynamic Update to Range in RANK Based on Date

I am building an NBA stats workbook where I have separate sheets for each stat (points, rebounds, etc.). For each individual stat, I am tracking this data in one sheet and I have the date of the game...
  • Patrick2788's avatar
    Patrick2788
    Dec 15, 2023

    Derharm1 

    Thanks for uploading the sample.

     

    This will work if you're in Excel 365. I created a few dynamic ranges so this formula will be dynamic:

    =LET(
        GRank, LAMBDA(a, q,
            LET(
                game_date, SORT(FILTER(L5_LI, Dates = a), , -1),
                IF(q = "", "", XMATCH(q, game_date))
            )
        ),
        MAP(Dates, L5_LI, GRank)
    )

    Added some dummy data for 11/13 to test it.

Resources