[R] Printing data frame with million rows

Joshua Wiley jwiley.psych at gmail.com
Sun Aug 7 20:29:09 CEST 2011


Hi Vikas,

See ?print.default and ?options  Your options are to set max.print in
options higher or manually pass a max value to print.  I'm not sure if
it will let you print a million rows---print is typically used for
output meant for the user and (again typically) users do not read
through a million rows.  For transfering and storing data (which is
kind of what this sounds like), something like save, write.table or at
a more basic level, writeLines are typically used.

Cheers,

Josh

On Sun, Aug 7, 2011 at 11:08 AM, Bansal, Vikas <vikas.bansal at kcl.ac.uk> wrote:
> Dear all,
>
> I was working on number of files and at the end I got a data frame with approx. million rows.To prin this data frame in output, I used
>
> capture.output(print.data.frame(end,row.names=F), file = "summary", append = FALSE)
>
> where end is the name of my data frame and summary is the name of my output file.
>
> but when I checked the output there were only 10000 rows and at the last it was written-
>
> [ reached getOption("max.print") -- omitted 923750 rows ]]
>
> Can you please tell me what is wrong with my output code? I want to print all million rows in my output.
>
> Thanking you,
> Warm Regards
> Vikas Bansal
> Msc Bioinformatics
> Kings College London
> ______________________________________________
> 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.
>



-- 
Joshua Wiley
Ph.D. Student, Health Psychology
Programmer Analyst II, ATS Statistical Consulting Group
University of California, Los Angeles
https://joshuawiley.com/



More information about the R-help mailing list