[R] : how to select rows at random

Laura Rodriguez Murillo laura.lmurillo at gmail.com
Fri Mar 27 20:18:50 CET 2009


Sorry, I'm attaching part of the file I have. They go up to 2000 and I
would like to take a subset of around 300.


5001 1
5001 2
5001 3
5001 5
5001 6
5002 1
5002 2
5002 5
5002 6
5002 11
5002 15
5002 16
5003 1
5003 2
5003 5
5003 6
5004 1
5004 2
5004 5
5004 6
5004 10
5004 11
5004 12
5004 15
5004 16
5004 25
5004 26
5004 35
5004 36
5004 45
5004 46
5004 55


Thank you!

Laura

2009/3/27 jim holtman <jholtman at gmail.com>:
> ?sample
>
> On Fri, Mar 27, 2009 at 3:11 PM, Laura Rodriguez Murillo
> <laura.lmurillo at gmail.com> wrote:
>> Hi dear list,
>>
>> I have a list of around 2000 identifiers aranged in a dataframe in one
>> column and I would like to choose a random subset of these. I wonder
>> if somebody can tell me if I could do this with R...
>>
>> Thank you so much!
>>
>> Laura RM
>>
>> ______________________________________________
>> R-help at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>
>
>
>
> --
> Jim Holtman
> Cincinnati, OH
> +1 513 646 9390
>
> What is the problem that you are trying to solve?
>




More information about the R-help mailing list