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.
> 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
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
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
4 matches
Mail list logo