A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

average f(x)



 
 
Thread Tools Display Modes
  #1  
Old September 16th, 2003, 07:54 PM
briank
external usenet poster
 
Posts: n/a
Default average f(x)

Any ideas why this won't work?
=average(ADDRESS(4,26):address(4,33))
  #2  
Old September 16th, 2003, 08:27 PM
Chip Pearson
external usenet poster
 
Posts: n/a
Default average f(x)

You have to convert the strings returned by ADDRESS to an actual range using
INDIRECT. E.g.,

=AVERAGE(INDIRECT(ADDRESS(4,26)&":"&ADDRESS(4,33)) )


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
www.cpearson.com



"briank" wrote in message
...
Any ideas why this won't work?
=average(ADDRESS(4,26):address(4,33))



  #3  
Old September 16th, 2003, 09:36 PM
Harlan Grove
external usenet poster
 
Posts: n/a
Default average f(x)

"Chip Pearson" wrote...
You have to convert the strings returned by ADDRESS to an actual range using
INDIRECT. E.g.,

=AVERAGE(INDIRECT(ADDRESS(4,26)&":"&ADDRESS(4,33) ))

...

Or eliminate the unnecessary ADDRESS calls. Assuming this is actually
parametrized as =AVERAGE(INDIRECT(ADDRESS(w,x)&":"&ADDRESS(y,z))), try

=AVERAGE(INDIRECT("R"&w&"C"&x&":R"&y&"C"&z,0)) [safest]

or

=AVERAGE(OFFSET($A$1,x-1,w-1,y-w+1,z-x+1)) [shortest & maybe fastest]

--
Never attach files.
Snip unnecessary quoted text.
Never multipost (though crossposting is usually OK).
Don't change subject lines because it corrupts Google newsgroup archives.
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:09 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.