[R] bootstrap help

Ben Bolker bolker at ufl.edu
Mon Dec 7 00:32:34 CET 2009


casperyc <casperyc <at> hotmail.co.uk> writes:

> I have 49 pairs in my data.frame 'data'
> 
> x	y
> 76	80
> ...  ...
> 
> how do I get a bootstrap sample of size n=50?
> 

data[sample(nrow(data),size=50,replace=TRUE),]




More information about the R-help mailing list