Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I have a worksheet containing text items in multiple columns. Each row
represents an individual (n=189). I am trying to count the number of individuals who have at least one instance of a particular text entry (e.g. Harm Reduction). Now there are approximately 10 columns in which 'Harm Reduction' could appear but not all individuals will have this text entry across the columns. Therefore it is important that I only count the number of individuals (i.e. Rows) and NOT the number of occurrences of 'Harm Reduction'. I have been trying to use SUMPRODUCT but that only seems to count occurences. Has anyone got any ideas, please??!! Thanking anyone in advance, Roy |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi there.
I will assume that you have text items in columns B to K, say, in the range B2:K5 and you want to know how many rows contain some text in any of these columns (each row should represent an individual). That said, you may want to adapt the following formula to your actual range: =SUM(SIGN(MMULT(IF(NOT(ISERROR(SEARCH("Your Search Text",B2:K5))),1,0),TRANSPOSE(SIGN(COLUMN(B2:K2))) ))) SHIFT + CTRL + ENTER On the above formula, you should note: 1. It is an array formula, hence the need of the SHIFT + CTRL + ENTER key combination to finalize it. 2. B2:K2 is the first row of your ten column data. 3. B2:K5 is the entire range of your data. 4. This solution assumes that your columns are contiguous. Best regards, Otávio "Royegg" wrote: I have a worksheet containing text items in multiple columns. Each row represents an individual (n=189). I am trying to count the number of individuals who have at least one instance of a particular text entry (e.g. Harm Reduction). Now there are approximately 10 columns in which 'Harm Reduction' could appear but not all individuals will have this text entry across the columns. Therefore it is important that I only count the number of individuals (i.e. Rows) and NOT the number of occurrences of 'Harm Reduction'. I have been trying to use SUMPRODUCT but that only seems to count occurences. Has anyone got any ideas, please??!! Thanking anyone in advance, Roy |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
counting occurrences | Excel Discussion (Misc queries) | |||
Counting occurrences | Excel Discussion (Misc queries) | |||
Counting occurrences | Excel Discussion (Misc queries) | |||
Counting number of occurrences. | Excel Worksheet Functions | |||
Counting occurrences on a particular date | Excel Worksheet Functions |