Re: [R] summary of categorical variables

2008-01-21 Thread John Kane
Will not just apply(mydf, 2 table) give you what you want in a list format? --- [EMAIL PROTECTED] wrote: > Dear list, > > I have a data.frame with nine categorical variables > (0,1,2 and NAs) > that I would like to get the number of events for > each of them. I can > extract this using summa

Re: [R] summary of categorical variables

2008-01-21 Thread Chuck Cleland
On 1/21/2008 8:08 AM, [EMAIL PROTECTED] wrote: > Dear list, > > I have a data.frame with nine categorical variables (0,1,2 and NAs) > that I would like to get the number of events for each of them. I can > extract this using summary() for each variable at a time with the > as.factor()argument (

[R] summary of categorical variables

2008-01-21 Thread darteta001
Dear list, I have a data.frame with nine categorical variables (0,1,2 and NAs) that I would like to get the number of events for each of them. I can extract this using summary() for each variable at a time with the as.factor()argument (otherwise it will get me the mean value): >summary(as.fact