Look up left / right cell to get maximum value

thousand

New member
Joined
Apr 2, 2017
Messages
30
Reaction score
0
Points
0
Excel Version(s)
2010
I am trying to lookup a year and get the max value (either in the previous year or the following year) if there is a missing value (e.g. 2007).


Here is the table I have -
Country20012002200320042005200620072008
A123100140


Here is the table I want -
Country20012002200320042005200620072008
A123100140140


Any suggestions? Thanks :)
 
Assuming the word "Country" is in cell A1, then this formula placed in cell B3 and filled across will give you what you need : IF(AND(ISNUMBER(A2),ISNUMBER(C2),ISBLANK(B2)),MAX(A2,C2),""). You can then copy the results and "Paste special" the values into the row above.


Here is the table I have -
Country20012002200320042005200620072008
A123100140

Here is the table I want -
Country20012002200320042005200620072008
A123100140140


Any suggestions? Thanks :)[/QUOTE]
 
Back
Top