Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default How to count two cells occurrences in a worksheet

Dear Expert,
I have a excel worksheet of 5 column and 100 rows with random cells values, I would like to count the occurrence of two cells in the worksheet. For example, if A1=1, A2=3 and C5=1 and C6=3 then the occurrence number is 2, and so on...

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,393
Default How to count two cells occurrences in a worksheet

Do you wish to count how many times two adjacent cells hold the same
numbers? Is this any pairs of numbers or 1 and 3 specifically? Does (1, 3)
match (3, 1) or is the order important?
--
Bernard V Liengme
Microsoft Excel MVP
http://people.stfx.ca/bliengme
remove caps from email

<ben mustapha wrote in message ...
Dear Expert,
I have a excel worksheet of 5 column and 100 rows with random cells
values, I would like to count the occurrence of two cells in the
worksheet. For example, if A1=1, A2=3 and C5=1 and C6=3 then the
occurrence number is 2, and so on...

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,805
Default How to count two cells occurrences in a worksheet

Need more information...

Do you want to count the occurences of each number in the worksheet?
=Countif(A1:E100,1) will give you the count of times 1 occurs in first five
columns and 100 rows...

"ben mustapha" wrote:

Dear Expert,
I have a excel worksheet of 5 column and 100 rows with random cells values, I would like to count the occurrence of two cells in the worksheet. For example, if A1=1, A2=3 and C5=1 and C6=3 then the occurrence number is 2, and so on...

Thanks

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,344
Default How to count two cells occurrences in a worksheet

Hi,

Here's what you want:

=SUMPRODUCT(--(COUNTIF(A1:E100,A1:E100)=2))

--
Thanks,
Shane Devenshire


"ben mustapha" wrote:

Dear Expert,
I have a excel worksheet of 5 column and 100 rows with random cells values, I would like to count the occurrence of two cells in the worksheet. For example, if A1=1, A2=3 and C5=1 and C6=3 then the occurrence number is 2, and so on...

Thanks

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
Count Unique Occurrences Brandon G. Excel Worksheet Functions 3 August 12th 08 12:43 PM
formula to count occurrences Libby Excel Worksheet Functions 5 March 28th 08 06:07 PM
trying to COUNT occurrences when certain criteria is met Allan from Melbourne Excel Discussion (Misc queries) 4 August 2nd 06 11:01 AM
Count number of occurrences MarkM Excel Discussion (Misc queries) 1 July 27th 06 10:14 PM
Count unique occurrences of name jhicsupt Excel Discussion (Misc queries) 4 October 5th 05 05:46 PM


All times are GMT +1. The time now is 08:54 PM.

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

About Us

"It's about Microsoft Excel"