Re: [R] how to get the numbers of factors in a matrix

2014-01-22 Thread peter dalgaard
r-project.org [mailto:r-help-boun...@r-project.org] On >> Behalf >> Of PIKAL Petr >> Sent: Tuesday, January 21, 2014 11:29 PM >> To: 张以春 >> Cc: r-help@r-project.org >> Subject: Re: [R] how to get the numbers of factors in a matrix >> >> Hi >> &g

Re: [R] how to get the numbers of factors in a matrix

2014-01-22 Thread William Dunlap
essage- > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On > Behalf > Of PIKAL Petr > Sent: Tuesday, January 21, 2014 11:29 PM > To: 张以春 > Cc: r-help@r-project.org > Subject: Re: [R] how to get the numbers of factors in a matrix > > Hi > &

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread PIKAL Petr
-project.org Subject: Re: RE: [R] how to get the numbers of factors in a matrix Dear Pikal, Thank you very much for your answer. I think your example is just the problem I have. In the following example you gave to me, > > ff<-factor(letters[1:5]) > > levels(ff[1:2]) > [1]

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread peter dalgaard
On 21 Jan 2014, at 15:58 , Jeff Newmiller wrote: > You are mis-using factors. Would you pretend that women do not exist just > because your sample happens to include only men? > > If you really need to ignore those other levels, convert your factor to > character and summarize those values.

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread Jeff Newmiller
just want to split the >matrix into many subsets and calculate the levels of every subset. Can >you tell me how to do? Thank you very much! > > >Best regards, >Yichun > >> -- >> �: "PIKAL Petr" >> : 2014���1���

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread 张以春
confused. Best, Yichun > -原始邮件- > 发件人: "Liu, Jun Yi" <7yu...@gmail.com> > 发送时间: 2014年1月21日 星期二 > 收件人: "张以春" , r-help@r-project.org > 抄送: > 主题: Re: [R] how to get the numbers of factors in

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread 张以春
he matrix into many subsets and calculate the levels of every subset. Can you tell me how to do? Thank you very much! Best regards, Yichun > -原始邮件- > 发件人: "PIKAL Petr" > 发送时间: 2014年1月21日 星期二 > 收件人: "张以春"

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread PIKAL Petr
sday, January 21, 2014 7:36 AM > To: r-help@r-project.org > Subject: [R] how to get the numbers of factors in a matrix > > Dear friends, > > > I have a question do not know how to resolve. > > > I have a big matrix composed of different columns (I use N here). A

Re: [R] how to get the numbers of factors in a matrix

2014-01-21 Thread Liu , Jun Yi
: 张以春 yczh...@nigpas.ac.cn Reply: 张以春 yczh...@nigpas.ac.cn Date: 21 January 2014 at 16:57:38 To: r-help@r-project.org r-help@r-project.org Subject:  [R] how to get the numbers of factors in a matrix > > Dear friends, > > > I have a question do not know how to resolve. > > &g

[R] how to get the numbers of factors in a matrix

2014-01-21 Thread 张以春
Dear friends, I have a question do not know how to resolve. I have a big matrix composed of different columns (I use N here). A column is "species" and another one is "latitudes". Now, I want to know how I can get the number of different "latitudes" for every "species". I have tried to split