Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ken Ken is offline
external usenet poster
 
Posts: 590
Default frequency a number repeats in a column

I have a spreadsheet that is 8 columns by 1000 rows. each cell contains a
number from 1 to 100. I need to find out which numbers in each column repeat
the most often, then the next most frequent.

I thought that the frequency command would do it but I can't make it work on
my data.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,081
Default frequency a number repeats in a column

Use Mode() to find the most frequent #
Use the array formula (committed with Ctrl-Shift-Enter) of

=MODE(IF(range of numbers<first mode formula,range of numbers))




"Ken" wrote:

I have a spreadsheet that is 8 columns by 1000 rows. each cell contains a
number from 1 to 100. I need to find out which numbers in each column repeat
the most often, then the next most frequent.

I thought that the frequency command would do it but I can't make it work on
my data.

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default frequency a number repeats in a column

Ken wrote...
I have a spreadsheet that is 8 columns by 1000 rows. each cell contains
a number from 1 to 100. I need to find out which numbers in each column
repeat the most often, then the next most frequent.

....

If your data were in A3:H1002, and you wanted the most frequent values
in row 1005 (so most frequent in A3:A1002 in A1005, etc.), next most
frequent values in row 1006, etc., try these formulas.

A1005:
=MODE(A$3:A$1002)

A1006 [array formula]:
=MODE(IF(COUNTIF(A$1005:A1005,A$3:A$1002)=0,A$3:A$ 1002))

Fill A1005:A1006 right into B1005:H1006. If you want 3rd most frequent
values in row 1007, select A1006:H1006 and fill down into A1007:H1007.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ken Ken is offline
external usenet poster
 
Posts: 590
Default frequency a number repeats in a column

Thanks Harlan,
I entered the formula as you listed them and I get a #N/A (Data Not
Available) error. My data fields run from C2:H975 I modified the ones you
listed to reflect the cells that I have in my array. Any suggestions?
C980 =MODE(C$2:C$975)
C981 =MODE(IF(COUNTIF(C$980:C980,C$2:C$975)=0,C$2:C$975 ))

"Harlan Grove" wrote:

Ken wrote...
I have a spreadsheet that is 8 columns by 1000 rows. each cell contains
a number from 1 to 100. I need to find out which numbers in each column
repeat the most often, then the next most frequent.

....

If your data were in A3:H1002, and you wanted the most frequent values
in row 1005 (so most frequent in A3:A1002 in A1005, etc.), next most
frequent values in row 1006, etc., try these formulas.

A1005:
=MODE(A$3:A$1002)

A1006 [array formula]:
=MODE(IF(COUNTIF(A$1005:A1005,A$3:A$1002)=0,A$3:A$ 1002))

Fill A1005:A1006 right into B1005:H1006. If you want 3rd most frequent
values in row 1007, select A1006:H1006 and fill down into A1007:H1007.


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default frequency a number repeats in a column

Ken wrote...
I entered the formula as you listed them and I get a #N/A (Data Not
Available) error. . . .

....
"Harlan Grove" wrote:

....
A1006 [array formula]:
=MODE(IF(COUNTIF(A$1005:A1005,A$3:A$1002)=0,A$3: A$1002))

....

I did say array formula. That means you need to type the formula, then
hold down [Shift] and [Ctrl] keys before pressing the [Enter] key to
enter the formula. If the formula returns #N/A when entered as an
array formula, it may mean you don't have any other values that appear
more than once.



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default frequency a number repeats in a column

If the formula returns #N/A when entered as an
array formula, it may mean you don't have any other
values that appear more than once.


If you want the numbers that only appear once to also be listed:

C980 =MODE(rng)

C981 array entered

=IF(ROWS($1:2)<=COUNT(1/FREQUENCY(rng,rng)),MODE(IF(ISNUMBER(rng),IF(COUNT IF(C$980:C980,rng)=0,rng+{0,0}))),"")

C981 copied down until you get blanks

Biff

"Harlan Grove" wrote in message
oups.com...
Ken wrote...
I entered the formula as you listed them and I get a #N/A (Data Not
Available) error. . . .

...
"Harlan Grove" wrote:

...
A1006 [array formula]:
=MODE(IF(COUNTIF(A$1005:A1005,A$3:A$1002)=0,A$3 :A$1002))

...

I did say array formula. That means you need to type the formula, then
hold down [Shift] and [Ctrl] keys before pressing the [Enter] key to
enter the formula. If the formula returns #N/A when entered as an
array formula, it may mean you don't have any other values that appear
more than once.



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
=sum(A:A) add to column (B) and new value repeats w/ new sums planecents Excel Worksheet Functions 3 March 2nd 07 05:35 PM
How can I count the number of repeats in a list of data? SouthCarolina Excel Discussion (Misc queries) 7 March 7th 06 10:03 PM
function for finding repeats in a column... killertofu Excel Worksheet Functions 2 February 21st 06 08:03 PM
How do I count the frequency of a given number in a column? dykstra_sj New Users to Excel 6 February 2nd 06 08:32 PM
no repeats in a column repeat Excel Worksheet Functions 2 November 3rd 04 09:36 PM


All times are GMT +1. The time now is 10:17 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"