[R] random samples

Kevin Wang Kevin.Wang at maths.anu.edu.au
Thu Jan 13 14:09:47 CET 2005


Hi,

On Thu, 13 Jan 2005 nicolas.deig at epfl.ch wrote:

>
> > A<-c(1:200)
> > S<-sample(A,100)
> selected in S to be put in another array, there is my problem!
> Is there anyway to do this with a function of R or should I do one by myself?

Something like:
 A[-S]
should do, I think.

Kev

--------------------------------
Ko-Kang Kevin Wang
PhD Student
Centre for Mathematics and its Applications
Building 27, Room 1004
Mathematical Sciences Institute (MSI)
Australian National University
Canberra, ACT 0200
Australia

Homepage: http://wwwmaths.anu.edu.au/~wangk/
Ph (W): +61-2-6125-2431
Ph (H): +61-2-6125-7407
Ph (M): +61-40-451-8301




More information about the R-help mailing list