Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
old grey whiskers
 
Posts: n/a
Default How can I count values greater than and less than certain values?

How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers
  #2   Report Post  
Ashish Mathur
 
Posts: n/a
Default

Hi,

Assuming the height range is in C1:C9.

Now array enter (Ctrl+Shift+Enter) the following formula in cell C11

=COUNT(IF((C5:C92)*(C5:C9<5),C5:C9))

Regards,


"old grey whiskers" wrote:

How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers

  #3   Report Post  
Trevor Shuttleworth
 
Posts: n/a
Default

One way:

=COUNTIF(A:A,"=170")-COUNTIF(A:A,"175")

Regards

Trevor


"old grey whiskers" wrote in
message ...
How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel
to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers



  #4   Report Post  
Aladin Akyurek
 
Posts: n/a
Default

=COUNTIF(AgeRange,"="&170)-COUNTIF(Range,""&175)

for an inclusive count.

=COUNTIF(AgeRange,""&170)-COUNTIF(Range,"="&175)

for an exclusive count.

old grey whiskers wrote:
How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?

  #5   Report Post  
old grey whiskers
 
Posts: n/a
Default

thanks Trevor that's a great help.
--
old grey whiskers


"Trevor Shuttleworth" wrote:

One way:

=COUNTIF(A:A,"=170")-COUNTIF(A:A,"175")

Regards

Trevor


"old grey whiskers" wrote in
message ...
How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel
to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers






  #6   Report Post  
old grey whiskers
 
Posts: n/a
Default

thanks Ashish that's a great help
--
old grey whiskers


"Ashish Mathur" wrote:

Hi,

Assuming the height range is in C1:C9.

Now array enter (Ctrl+Shift+Enter) the following formula in cell C11

=COUNT(IF((C5:C92)*(C5:C9<5),C5:C9))

Regards,


"old grey whiskers" wrote:

How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers

  #7   Report Post  
Trevor Shuttleworth
 
Posts: n/a
Default

And another option for the collection ...

=SUMPRODUCT((A1:A500=170)*(A1:A500<=175))

Regards

Trevor


"old grey whiskers" wrote in
message ...
How can I count occurances in a range of values. Eg If I have a class of
students ranging from 150cm to 190cm height, what is the formula in Excel
to
count how many people are between 170 and 175 cm. How can I count values
greater than and less than in one operation?
--
old grey whiskers



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



All times are GMT +1. The time now is 10:33 AM.

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"