help with COUNTIF formula

A

acandray

Version: 2008
Operating System: Mac OS X 10.5 (Leopard)
Processor: Intel

hello I need to construct a formula that will let me count how many cells have numbers between 0 and 2, however I don't know how to adapt the criteria to fit this range <2 and >0.

=COUNTIF(Sheet1!48:48,"<=2")
 
M

Mike Middleton

acandray -

If the data range is cells A1:A48 on Sheet1, and if you want a count of
cells with numbers strictly greater than zero and strictly less than two,
i.e., >0 and <2, then you could use

=COUNTIF(Sheet1!A1:A48,"<2")-COUNTIF(Sheet1!A1:A48,"<=0")

- Mike Middleton
http://www.DecisionToolworks.com
Decision Analysis Add-ins for Excel
 
C

Carl Witthoft

Or you could use Array Formulas. Basically, break up the function into
its parts:

=COUNT(IF(AND([data]<2,[data]>0,1,0)))
Remember to enter as an Array Formula (Shift-Control-Return in Win,
Shift-CMD-Return in Mac -- someone please correct me if my memory has
failed me :-( )
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

help with countif formula 2
formula error 1
Using COUNTIF but blank cell if zero 3
Auto hide in excel 2008 8
error with exel 1
Countif formula for specific text within range 1
Count IF Question 1
Formula Bar 5

Top