[Rd] write.matrix has limited line length -> truncation (PR#2722)

christen at chemie.hu-berlin.de christen at chemie.hu-berlin.de
Thu Apr 3 09:49:06 MEST 2003

Full_Name: Dr. Wolfgang Christen
Version: 1.62
OS: Windows 2000
Submission from: (NULL) (

I have a matrix of 705 x 999 elements and would like to save the data to a file
using the follwing line:
write.matrix ( format ( U1r, digits = 15 ), file = "C:\\Documents and
Settings\\Administrator\\My Documents\\R\\plot-u2-2.txt" )

Then I had to find out that only 195 (out of 705) columns were saved :-(

I tried then to reduce the accuracy to 5 digits, which gave me 373 columns,
already better, but still insufficient. 

So my suspicion is that an internal line buffer is limited to something less
than 4k and all subsequent data gets truncated and thus will not be saved.

More information about the R-devel mailing list