[R] Sampling

Judith Flores juryef at yahoo.com
Tue Feb 5 19:52:06 CET 2008


Hi there,

   I want to generate different samples using the
followindg code:


g<-sample(LETTERS[1:2], 24, replace=T)

   How can I specify that I need 12 "A"s and 12 "B"s?

Thank you,

Judith


      ____________________________________________________________________________________
Be a better friend, newshound, and



More information about the R-help mailing list