#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 134
Default countif??

Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default countif??

Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 134
Default countif??

Mike tks for your prompt reply.

need only to count the last (in this case 3) < from 4

is it possible to adapt the formula??

Tks in advance

"Mike H" wrote:

Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default countif??

My reading of the question is that the requirement is to start counting with
the last non-blank cell in the column, and move up the column counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default countif??

Maybe

=COUNTIF((INDIRECT("A" &MATCH(10^100,A:A)-2 &":a" & MATCH(10^100,A:A))),"<4")

Mike

"Antonio" wrote:

Mike tks for your prompt reply.

need only to count the last (in this case 3) < from 4

is it possible to adapt the formula??

Tks in advance

"Mike H" wrote:

Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default countif??

Maybe better

Use this and enter into B1 to amount of cells from the bottom you want to
include in the calculation.

=COUNTIF((INDIRECT("A" &MATCH(10^100,A:A)-(B1-1) &":a" &
MATCH(10^100,A:A))),"<4")

Mike



"Mike H" wrote:

Maybe

=COUNTIF((INDIRECT("A" &MATCH(10^100,A:A)-2 &":a" & MATCH(10^100,A:A))),"<4")

Mike

"Antonio" wrote:

Mike tks for your prompt reply.

need only to count the last (in this case 3) < from 4

is it possible to adapt the formula??

Tks in advance

"Mike H" wrote:

Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António

  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default countif??

I amost certainly don't understand but my latest guess is take the last n
values in the column and see how may are <4

We shall see:)

Mike

"David Biddulph" wrote:

My reading of the question is that the requirement is to start counting with
the last non-blank cell in the column, and move up the column counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António




  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default countif??

This formula also returns 14:

=COUNTIF(A:A,"<4")

Pete

On May 9, 11:07*am, Antonio wrote:
Hi all

Looking for a formula that count's, from last cell (undifined) upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António


  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 134
Default countif??

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start counting with
the last non-blank cell in the column, and move up the column counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António




  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default countif??

The number of cells over which to count (the number you want to put in B1)
is the number (counting upwards from he foot of the column) until you get to
a cell with 4 in it.
--
David Biddulph

"Mike H" wrote in message
...
Maybe better

Use this and enter into B1 to amount of cells from the bottom you want to
include in the calculation.

=COUNTIF((INDIRECT("A" &MATCH(10^100,A:A)-(B1-1) &":a" &
MATCH(10^100,A:A))),"<4")

Mike



"Mike H" wrote:

Maybe

=COUNTIF((INDIRECT("A" &MATCH(10^100,A:A)-2 &":a" &
MATCH(10^100,A:A))),"<4")

Mike

"Antonio" wrote:

Mike tks for your prompt reply.

need only to count the last (in this case 3) < from 4

is it possible to adapt the formula??

Tks in advance

"Mike H" wrote:

Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined)
upwards how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António





  #11   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default countif??

Then that's what you have in my previous post

"Antonio" wrote:

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start counting with
the last non-blank cell in the column, and move up the column counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António




  #12   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 134
Default countif??

Hi mike

tryed it, and seems it's not working, because when column
a "grows and more then a 4 in it, returns the total of non 4

"Mike H" wrote:

Then that's what you have in my previous post

"Antonio" wrote:

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start counting with
the last non-blank cell in the column, and move up the column counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" & MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined) upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António



  #13   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,572
Default countif??

With data in Column A, this *array* formula will give you the number of
cells between the last 4 and the last cell containing a number:

=MATCH(99^99,A1:A50)-MAX(IF(A1:A50=4,ROW(1:50)))

--
Array formulas must be entered with CSE, <Ctrl <Shift <Enter, instead of
the regular <Enter, which will *automatically* enclose the formula in curly
brackets, which *cannot* be done manually. Also, you must use CSE when
revising the formula.

This will count cells between the last 4 and the last number, whether or not
there is any data in those "in-between" cells.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"Antonio" wrote in message
...
Hi mike

tryed it, and seems it's not working, because when column
a "grows and more then a 4 in it, returns the total of non 4

"Mike H" wrote:

Then that's what you have in my previous post

"Antonio" wrote:

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start
counting with
the last non-blank cell in the column, and move up the column
counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" &
MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined)
upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António





  #14   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 134
Default countif??

Tks very much to all for the help given

With this formula, got the expected result

Tks

"RagDyer" wrote:

With data in Column A, this *array* formula will give you the number of
cells between the last 4 and the last cell containing a number:

=MATCH(99^99,A1:A50)-MAX(IF(A1:A50=4,ROW(1:50)))

--
Array formulas must be entered with CSE, <Ctrl <Shift <Enter, instead of
the regular <Enter, which will *automatically* enclose the formula in curly
brackets, which *cannot* be done manually. Also, you must use CSE when
revising the formula.

This will count cells between the last 4 and the last number, whether or not
there is any data in those "in-between" cells.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"Antonio" wrote in message
...
Hi mike

tryed it, and seems it's not working, because when column
a "grows and more then a 4 in it, returns the total of non 4

"Mike H" wrote:

Then that's what you have in my previous post

"Antonio" wrote:

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start
counting with
the last non-blank cell in the column, and move up the column
counting up
while the cell value is not 4, and stopping when a 4 is encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with this
formula

=COUNTIF((INDIRECT("a1:a" &
MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined)
upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António






  #15   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,572
Default countif??

Your feed-back is appreciated.
--

Regards,

RD
-----------------------------------------------------------------------------------------------
Please keep all correspondence within the Group, so all may benefit !
-----------------------------------------------------------------------------------------------

"Antonio" wrote in message
...
Tks very much to all for the help given

With this formula, got the expected result

Tks

"RagDyer" wrote:

With data in Column A, this *array* formula will give you the number of
cells between the last 4 and the last cell containing a number:

=MATCH(99^99,A1:A50)-MAX(IF(A1:A50=4,ROW(1:50)))

--
Array formulas must be entered with CSE, <Ctrl <Shift <Enter, instead
of
the regular <Enter, which will *automatically* enclose the formula in
curly
brackets, which *cannot* be done manually. Also, you must use CSE when
revising the formula.

This will count cells between the last 4 and the last number, whether or
not
there is any data in those "in-between" cells.
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------
"Antonio" wrote in message
...
Hi mike

tryed it, and seems it's not working, because when column
a "grows and more then a 4 in it, returns the total of non 4

"Mike H" wrote:

Then that's what you have in my previous post

"Antonio" wrote:

thats what i lookinf 4

"David Biddulph" wrote:

My reading of the question is that the requirement is to start
counting with
the last non-blank cell in the column, and move up the column
counting up
while the cell value is not 4, and stopping when a 4 is
encountered.
--
David Biddulph

"Mike H" wrote in message
...
Hi,

Why are there only 3 numbers <4 in that list? I count 14 with
this
formula

=COUNTIF((INDIRECT("a1:a" &
MATCH(9.99999999999999E+307,A:A))),"<4")

Mike

"Antonio" wrote:

Hi all

Looking for a formula that count's, from last cell (undifined)
upwards
how
many cell < from 4, which from the list below should return 3

3
5
4
5
3
4
4
2
4
3
4
4
3
5
6
4
4
3
3
4
2
3
2

tks in advance
António








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
Countif Mifty Excel Discussion (Misc queries) 6 November 14th 07 08:43 PM
How do I use a countif function according to two other countif fu. Kirsty Excel Worksheet Functions 2 February 20th 06 11:44 AM
edit this =COUNTIF(A1:F16,"*1-2*")+COUNTIF(A1:F16,"*2-1*") sctroy Excel Discussion (Misc queries) 2 September 25th 05 04:13 AM
COUNTIF or not to COUNTIF on a range in another sheet Ellie Excel Worksheet Functions 4 September 15th 05 10:06 PM
COUNTIF in one colum then COUNTIF in another...??? JonnieP Excel Worksheet Functions 3 February 22nd 05 02:55 PM


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

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

About Us

"It's about Microsoft Excel"