[R] print one character on several lines

From: Hua Li <hualihua_at_yahoo.com>
Date: Thu, 19 Jun 2008 14:33:30 -0700 (PDT)

Hi All,

I'm wondering how I can print one large/long character on several lines so that the output will not overflow a page. Setting fill be TRUE or even numbers does not help. An example is below:

ipuFile <- file("input.txt", "w")     

cat("This is a very long character and I want to print it on several lines. This is a very long character and I want to print it on several lines.",fill = TRUE,file = ipuFile)       




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 19 Jun 2008 - 22:37:44 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 Fri 20 Jun 2008 - 12:31:01 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