Re: [R] Select a group of data from a file

2008-01-18 Thread John Kane
Hi ? subset should do it xx < subset(x, x$Var2==1) --- "LA SPINA, MICHELANGELO" <[EMAIL PROTECTED]> wrote: > Hello everybody! > > I've a file with several data six variables, three > quantitative and three qualitative, I would like to > select a group of data from the file to analyze > then, i.

Re: [R] Select a group of data from a file

2008-01-18 Thread Richard . Cotton
> I've a file with several data six variables, three quantitative and > three qualitative, I would like to select a group of data from the > file to analyze then, i.e: > my file is like that (but with 6 variables): > > Var1 Var2 > 2 1 > 5 1 > 8 1 > 7 2 > 3 2 > 8

Re: [R] Select a group of data from a file

2008-01-18 Thread Jeremy Baxter
Try subset. help(subset) Subset returns a subsets of vectors, matrices or data frames which meet conditions. There are some excellent examples in the help. Here is an example similar to your email. Create some data: Var1<-sample(1:10,20,replace=TRUE) Var2<-sample(1:10,20,replace=TRUE) the.o

[R] Select a group of data from a file

2008-01-18 Thread LA SPINA, MICHELANGELO
Hello everybody! I've a file with several data six variables, three quantitative and three qualitative, I would like to select a group of data from the file to analyze then, i.e: my file is like that (but with 6 variables): Var1 Var2 2 1 5 1 8 1 7 2 3 2 8 2