Reference Level for grouped rows

Occasional Visitor

Hi, 

 

I am looking to reference the row level for grouped rows in a data set. Please see snip below. Is there a formula which returns 1 for level 1, 2 for level 2 and so on as pasted in column A?

 

Thank you. 

 

SKB90_0-1657274584105.png

 

2 Replies
I am not aware of such a function but you may be able to achieve something with SUBTOTAL(102;...). I am not sure what you are trying to do. If your aim is for L4 to be the SUM of L5, you will find that SUBTOTAL can do that for you anyway.
Maybe you can use a filter on the header row(?)