Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 57
Default Most and least common

I need to find both the most and the least common text values in a column.
For instance, if I have ten entries reading "Tuesday" and three "Monday", I'd
like to be able to return "Tuesday" as the most common and "Monday" as the
least common value.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 248
Default Most and least common

Assuming you have your values in Col A
then type this in B1
=INDIRECT("A"&MATCH(MAX(COUNTIF(A1:A30,A1:A30)),CO UNTIF(A1:A30,A1:A30),0))
and
IMP:- press CTRL-SHIFT-ENTER as this is an ARRAY formula, to get the Max
entry..

and this for MIN in B2
=INDIRECT("A"&MATCH(MIN(COUNTIF(A1:A30,A1:A30)),CO UNTIF(A1:A30,A1:A30),0))

-------------------------------------
Pl. click ''Yes'' if this was helpful...



"jmj713" wrote:

I need to find both the most and the least common text values in a column.
For instance, if I have ten entries reading "Tuesday" and three "Monday", I'd
like to be able to return "Tuesday" as the most common and "Monday" as the
least common value.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default Most and least common

Let's do this the easy way:

Assume your range of data is A1:A10
Enter this formula in B1 and copy down to B10:

=COUNTIF(A$1:A$10,A1)

For the most common item:

=INDEX(A1:A10,MATCH(MAX(B1:B10),B1:B10,0))

For the least common item:

=INDEX(A1:A10,MATCH(MIN(B1:B10),B1:B10,0))

If there are more than one most/least common item the formula returns the
*first* instance from top to bottom.

--
Biff
Microsoft Excel MVP


"jmj713" wrote in message
...
I need to find both the most and the least common text values in a column.
For instance, if I have ten entries reading "Tuesday" and three "Monday",
I'd
like to be able to return "Tuesday" as the most common and "Monday" as the
least common value.



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
Second Most Common Value Skalp Excel Discussion (Misc queries) 6 May 9th 23 07:43 PM
Common footer but not common margins please -(Page 1 of 2) etc RajenRajput1 Excel Discussion (Misc queries) 9 August 26th 08 06:56 PM
I still cant get the six most common numbers to come up tht Excel Discussion (Misc queries) 1 May 29th 07 05:09 AM
Common Private Sub Booker Excel Discussion (Misc queries) 1 November 15th 05 08:50 AM
Common spacing RAJEEV CHADHA Excel Worksheet Functions 0 April 26th 05 01:29 PM


All times are GMT +1. The time now is 10:56 AM.

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"