counting the number of entries with conditions

AHALEY

New Member
Joined
Jul 21, 2011
Messages
6
I have a group of data, and I am trying to provide a simple count of the number of entries that are equal to or less than 100, less than 200 but greater than 100, etc. I have brain lock around COUNT() COUNTIF() and IF statements and am having issues working out how to get these to do what I am needing.

In addition, I am trying to average each row of data, and providing a running average for the entire series of data, but need to exclude in the average calculation any entries that are either 0 or #N/A.

I'm sure these are fairly simple problems, but I am stumped....

Any help would be appreciated
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
These are all CSE formulas, meaning after you type them in you have to press Ctrl, Shift, and Enter

Less then 100
=COUNT(IF(A2:A5<=100,A2:A5))

Between 100-200
=COUNT(IF((A2:A5<=200)*(A2:A5>=100),A2:A5))
 
Upvote 0
I have a group of data, and I am trying to provide a simple count of the number of entries that are equal to or less than 100, less than 200 but greater than 100, etc. I have brain lock around COUNT() COUNTIF() and IF statements and am having issues working out how to get these to do what I am needing.

In addition, I am trying to average each row of data, and providing a running average for the entire series of data, but need to exclude in the average calculation any entries that are either 0 or #N/A.

I'm sure these are fairly simple problems, but I am stumped....

Any help would be appreciated
Try these...

Count numbers <=100...

=COUNTIF(A2:A100,"<=100")

Count numbers >100 and <=200...

=COUNTIF(A2:A100,">100")-COUNTIF(A2:A100,">200")

Average numbers >0 and ignore any errors...

Array entered**:

=AVERAGE(IF(ISNUMBER(A1:A100),IF(A1:A100>0,A1:A100)))

** array formulas need to be entered using the key
combination of CTRL,SHIFT,ENTER (not just ENTER).
Hold down both the CTRL key and the SHIFT key
then hit ENTER.
 
Upvote 0

Forum statistics

Threads
1,224,559
Messages
6,179,513
Members
452,921
Latest member
BBQKING

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top