View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Glenn Glenn is offline
external usenet poster
 
Posts: 1,240
Default counting values in a column

Jerry wrote:
I have different values in a a column that I need to count.
Column A: 2,25,45,52,25,30,2,45,80,60
and I want to count values as follows
<30 = 4
30 and <60 = 4
60 = 2

I have tried countif and sumproduct but it doesn't work correctly. Your
assistance is greatly appreciated.



One way:

B1=COUNTIF(A:A,"<30")

B2=COUNTIF(A:A,"<60")-B1

B3=COUNT(A:A)-SUM(B1:B2)