I have a long column of numbers. I want to know how many of those numbers are followed by an "8" in the next item (next row). What's the best way to compute that?
I have a long column of numbers. I want to know how many of those numbers are followed by an "8" in the next item (next row). What's the best way to compute that?
If column A is all numbers then you dont have to check anything there.
It's simply how many 8's are in column B use
COUNTIF(B1:B1000,"8")
But if you want to know how many "8" are in column B that have, e.g. "abc" in column A then use
COUNTIFS(A1:A1000,"abc",B1:B1000,"8")
Regards
Special-K
Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.
If you have the value 3 in A1, and the value 8 in A2, are you wanting to count the 3? If so something like =countif(A:A,8) would work. It would actually count the number 8 rather than the numbers that are in the row prior to a value of 8.
If that doesn't meet your needs try uploading a sample workbook that shows what exactly you require.
Sorry I was unclear. What I need to count are the number of 8's that are preceded by a non-8 in the previous value.
For example, if my column was
1
2
8
8
8
4
5
8
3
then I want to have the answer 2, because there are 2 8's following non-8 numbers (the ones after the 2 and the 5).
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks