Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Bruce
 
Posts: n/a
Default how can i calc averageif

How could I calc an averageif in a similar way to the sumif function?

i.e. Average if A2 = B2 from C2

Bruce
  #2   Report Post  
Dave Peterson
 
Posts: n/a
Default

=average(if(a1:a1017,a1:a10))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

This will average only the numbers in A1:A10 that are greater than 17.

(I'm not quite sure how to translate your example, though.)

Bruce wrote:

How could I calc an averageif in a similar way to the sumif function?

i.e. Average if A2 = B2 from C2

Bruce


--

Dave Peterson
  #3   Report Post  
Bruce
 
Posts: n/a
Default

Ok, thanks Dave,

I used =AVERAGE(IF('On Promotion'!$D58:$BC58=0,$D58:$BC58)) in my sheet and
it works.

My next step is to add a second condition to my sheet like this

=AVERAGE(IF(AND('On Promotion'!$D58:$BC58=0,D58:BC58<0),$D58:$BC58)) but it
equals zero but it shouldn't.

basically i am trying to average if cond1 = 0 and cond2 < 0.

Any ideas?

Bruce

"Dave Peterson" wrote:

=average(if(a1:a1017,a1:a10))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

This will average only the numbers in A1:A10 that are greater than 17.

(I'm not quite sure how to translate your example, though.)

Bruce wrote:

How could I calc an averageif in a similar way to the sumif function?

i.e. Average if A2 = B2 from C2

Bruce


--

Dave Peterson

  #4   Report Post  
Dave Peterson
 
Posts: n/a
Default

Try:

=AVERAGE(IF(('On Promotion'!$D58:$BC58=0)*(D58:BC58<0),$D58:$BC58) )



Bruce wrote:

Ok, thanks Dave,

I used =AVERAGE(IF('On Promotion'!$D58:$BC58=0,$D58:$BC58)) in my sheet and
it works.

My next step is to add a second condition to my sheet like this

=AVERAGE(IF(AND('On Promotion'!$D58:$BC58=0,D58:BC58<0),$D58:$BC58)) but it
equals zero but it shouldn't.

basically i am trying to average if cond1 = 0 and cond2 < 0.

Any ideas?

Bruce

"Dave Peterson" wrote:

=average(if(a1:a1017,a1:a10))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

This will average only the numbers in A1:A10 that are greater than 17.

(I'm not quite sure how to translate your example, though.)

Bruce wrote:

How could I calc an averageif in a similar way to the sumif function?

i.e. Average if A2 = B2 from C2

Bruce


--

Dave Peterson


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Pivot Table - Calc Item Problem Scott Excel Worksheet Functions 2 June 2nd 05 01:53 AM
"AverageIF" alternative Flutie99 Excel Discussion (Misc queries) 2 May 27th 05 11:03 PM
How do you calc half day annual leave on a xls spread sheet using. RGayle_Imperial Excel Worksheet Functions 5 March 8th 05 08:34 PM
Create an AVERAGEIF function. as Excel Worksheet Functions 2 March 2nd 05 01:27 PM
AVERAGEIF Function out there? davidad Excel Discussion (Misc queries) 2 January 21st 05 05:52 PM


All times are GMT +1. The time now is 12:21 PM.

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

About Us

"It's about Microsoft Excel"