imperium1980
New Member
- Joined
- Feb 10, 2009
- Messages
- 27
Hi all,
There are any number of posts on this topic but all are based on data in adjacent columns. I have to get a cell to return the average of the last 5 values entered in a row but cannot get it to work. Probably because I can't fully understand what the row and column settings mean in the offset formula.
I have the folowing formula set up in A1.
=AVERAGE(OFFSET(B2,COUNT(B2:P2)-1,0,1,5))
In A2 I have "Produced" then some small integers from B2 to P2
In A3 I have "Average" then in G3 Formula =AVERAGE(C2:G2), H3 is =AVERAGE(D2:H2) etc.
Can anyone enlighten me as to what is wrong with my formula? Any help greatly appreciated.
Regards,
Neil
There are any number of posts on this topic but all are based on data in adjacent columns. I have to get a cell to return the average of the last 5 values entered in a row but cannot get it to work. Probably because I can't fully understand what the row and column settings mean in the offset formula.
I have the folowing formula set up in A1.
=AVERAGE(OFFSET(B2,COUNT(B2:P2)-1,0,1,5))
In A2 I have "Produced" then some small integers from B2 to P2
In A3 I have "Average" then in G3 Formula =AVERAGE(C2:G2), H3 is =AVERAGE(D2:H2) etc.
Can anyone enlighten me as to what is wrong with my formula? Any help greatly appreciated.
Regards,
Neil