If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
I am having trouble with the count function and setting it up to work in
my spreadsheet. Basically, I want to count the number of times that X comes up in a row, but ONLY have the occurence of Y. Basically, my rows are set up like this: W, L, W, W, L, L, W I want to count the number of times a "W" comes up after an "L". However, I don't want it to count ALL of the "W". I needs to only count the W when it is in the cell directly to the right of an "L". Any ideas? Thanks --- Message posted from http://www.ExcelForum.com/ |
#2
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
Hi
try =SUMPRODUCT(--(A1:W1="L"),--(B1:X1="W")) -- Regards Frank Kabel Frankfurt, Germany I am having trouble with the count function and setting it up to work in my spreadsheet. Basically, I want to count the number of times that X comes up in a row, but ONLY have the occurence of Y. Basically, my rows are set up like this: W, L, W, W, L, L, W I want to count the number of times a "W" comes up after an "L". However, I don't want it to count ALL of the "W". I needs to only count the W when it is in the cell directly to the right of an "L". Any ideas? Thanks --- Message posted from http://www.ExcelForum.com/ |
#3
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
Frank:
I asked this question earlier and I forgot in which thread I had asked...but here goes... what does "--" in the sumproduct formula mean...am eager to know.. Thanks, Kavir --- Message posted from http://www.ExcelForum.com/ |
#4
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
Hi
this double minus (unary operator) coerces the boolean values (TRUE/FALSE) ro numeric values (1/0) -- Regards Frank Kabel Frankfurt, Germany Frank: I asked this question earlier and I forgot in which thread I had asked...but here goes... what does "--" in the sumproduct formula mean...am eager to know.. Thanks, Kavir --- Message posted from http://www.ExcelForum.com/ |
#5
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
Frank:
You mean wherever the result would have been True/False, this forces it to be 1/0? Where else can you use it apart from sumproduct function. I tend to use the sumproduct function a lot and have fount it a very unique and powerful function a good replacement for the array functions. Thanks, Kavir --- Message posted from http://www.ExcelForum.com/ |
#6
|
|||
|
|||
COUNT: Counting the number of times "X" comes up after the occurrence of "Y"
Hi
you can also use it for converting numbers which are stored as text to real numbers. e.g. A1: ABC123 With the fomurla =RIFHT(A1,3) you would get '123'. But the result would be a text. Use =--RIGHT(A1,3) and you'll get a number -- Regards Frank Kabel Frankfurt, Germany Frank: You mean wherever the result would have been True/False, this forces it to be 1/0? Where else can you use it apart from sumproduct function. I tend to use the sumproduct function a lot and have fount it a very unique and powerful function a good replacement for the array functions. Thanks, Kavir --- Message posted from http://www.ExcelForum.com/ |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Counting number of certain entries | Holly Cetron | Running & Setting Up Queries | 2 | June 9th, 2004 12:46 AM |
Counting Number of Occurences of Various Times | Frank Kabel | Worksheet Functions | 4 | May 26th, 2004 03:38 PM |
Count number of occurances in column | acorbally | Worksheet Functions | 0 | May 3rd, 2004 06:09 PM |
Count number of chars or digits in a cell? Parse out last char? | RF | Worksheet Functions | 3 | March 17th, 2004 08:03 PM |
count number of times a word appears in a column | Tushar Mehta | Charts and Charting | 0 | November 15th, 2003 12:23 AM |