S
Stephen Allen
I am creating a summarising worksheet that evaluates a list of
numbers.
The list of numbers is held in a column of adjacent cells called
'ListVal1'. I wish to evaluate the numeric cells in 5 possible ways as
determined by the user - the analysis could be any one of SUM,
AVERAGE, MIN, MAX or COUNT. The user selects the analytical process by
reference to a text value in a related cell - in this case cell 'B11'.
The following formula works but is both cumbersome and has reached the
limit of nested 'if statements'
=IF(B11="","",IF(B11="SUM",SUM(ListVal1),IF(B11="AVERAGE",AVERAGE(ListVal1),IF(B11="MAX",MAX(ListVal1),IF(B11="MIN",MIN(ListVal1),IF(B11="COUNT",COUNT(ListVal1),""))))))
Does any one have a more flexible (less cumbersome) approach?
numbers.
The list of numbers is held in a column of adjacent cells called
'ListVal1'. I wish to evaluate the numeric cells in 5 possible ways as
determined by the user - the analysis could be any one of SUM,
AVERAGE, MIN, MAX or COUNT. The user selects the analytical process by
reference to a text value in a related cell - in this case cell 'B11'.
The following formula works but is both cumbersome and has reached the
limit of nested 'if statements'
=IF(B11="","",IF(B11="SUM",SUM(ListVal1),IF(B11="AVERAGE",AVERAGE(ListVal1),IF(B11="MAX",MAX(ListVal1),IF(B11="MIN",MIN(ListVal1),IF(B11="COUNT",COUNT(ListVal1),""))))))
Does any one have a more flexible (less cumbersome) approach?