Thierry,
Thanks so much. Your solution works perfectly.
Tony
-Original Message-
From: ONKELINX, Thierry [mailto:[EMAIL PROTECTED]
Sent: Monday, September 15, 2008 2:56 AM
To: Brown, Tony Nicholas; r-help@r-project.org
Subject: RE: [R] randomly sample within clustered data?
Something
:40
Aan: r-help@r-project.org
Onderwerp: [R] randomly sample within clustered data?
Dear useRs,
What is an efficient way to randomly sample from clustered data such
that I get equal representation from each cluster? For example, let's
say I want to randomly sample two cases from each cluster
Dear useRs,
What is an efficient way to randomly sample from clustered data such
that I get equal representation from each cluster? For example, let's
say I want to randomly sample two cases from each cluster created by the
"id" variable in the following data frame:
> id<-c(rep("100", 4),re
3 matches
Mail list logo