Re: [R] A question about data frame

From: Gang Chen <gangchen6_at_gmail.com>
Date: Thu, 10 Mar 2011 16:49:40 -0500

Thanks! You mean something like:

> print(df$s[1], max.levels=0)

It seems I could also do

> as.character(df$s[1])

Any other/better solutions?

On Thu, Mar 10, 2011 at 4:40 PM, Rob Tirrell <rpt_at_stanford.edu> wrote:
> See the max.levels argument in ?print. I think this is what you're looking
> for.
> --
> Robert Tirrell | rpt_at_stanford.edu | (607) 437-6532
> Program in Biomedical Informatics | Butte Lab | Stanford University
>
>
> On Thu, Mar 10, 2011 at 13:35, Gang Chen <gangchen6_at_gmail.com> wrote:
>>
>> n = c(2, 3, 5)
>> > s = c("aa", "bb", "cc")
>> > df = data.frame(n, s)
>



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 10 Mar 2011 - 21:51:46 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 10 Mar 2011 - 22:00:21 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive