Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 184
Default Random Sample with multiple data points

I have a list of people with a large number of lines per person. I need to
randomly select two lines for each person. The report is preformatted and
downloaded daily. The names are listed in column C. How can I do this?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Random Sample with multiple data points

Say we have 20 "Mike" lines, then 10 "James" lines, then 50 "Sally" lines, etc.

It does not matter if the lines are grouped together or not. In an un-used
column (say column Z), enter:

=RAND() and copy down

First the table by column Z. This will randomize the records. Then sort
the table by column C. This will group the names together, but in a random
order. All the "Mike"s will be grouped, but the order of the "Mike"s
shuffled.

Then just take the first two "Mike"s, the first two "James"s, etc.
--
Gary''s Student - gsnu200847


"Jeremy" wrote:

I have a list of people with a large number of lines per person. I need to
randomly select two lines for each person. The report is preformatted and
downloaded daily. The names are listed in column C. How can I do this?

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
Random Sample Funkyfido Excel Worksheet Functions 2 September 22nd 08 11:09 AM
can i do a random sample with non-numeric data? Kyeria Excel Discussion (Misc queries) 1 May 9th 07 10:51 PM
Selecting a Random Sample of 15 from a Large data set RMort Excel Worksheet Functions 6 December 22nd 06 05:09 PM
random sample skimpw Excel Worksheet Functions 0 August 15th 06 01:15 AM
Is it possible to do a random sample of non-numeric data in Excel? Terri G Excel Discussion (Misc queries) 4 December 15th 05 05:44 PM


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