Reputation: 53
I am trying to calculate the average in excel with two columns with the cell address data.
Here is an example:
Start End Average
$CL$2 $CP$2 =average($CL$2:$CP$2)
$AD$3 $AT$3 =average($AD$3:$AT$3)
$AD$4 $AT$4 =average($AD$4:$AT$4)
$AD$5 $AT$5 =average($AD$5:$AT$5)
When I click on the Cell it references the cell with the value in it and the average formula doesn't work
Thank you
Upvotes: 0
Views: 80
Reputation: 49998
Use the INDIRECT
function to return a reference specified by a text string - in this case, your starting and ending cell addresses, concatenated with the colon :
.
For example:
=AVERAGE(INDIRECT(A2&":"&B2))
Upvotes: 1