[R] A problem on sink() and format,suggestions appreciated
Yong Wang
wang at galton.uchicago.edu
Wed Jun 1 07:04:29 CEST 2005
Dear R users
I get a weired problem when use sink:
since the data set pretty big, I sink intermediate result for further
use,following
lines are consistently used when write data
###########################
sink("dataname.txt")
data
sink()
##########################
at first couples of run, all 10 variables are wrote to a file in following
format:
V1 V2 ....... V10
1 10457 132356.7 ....... 4356.8
2 75690.2 66697 ....... 98777
. ..................................
10000 654786 3412.54 ...... 98712.567
then I did modifcations somewhere else, the format change to:
V1 V2 ....... V9
1 10457 132356.7 ....... 7823.569
2 75690.2 66697 ....... 77024
. ..................................
10000 654786 3412.54 ...... 336721
V10
1 4356.8
2 98777
. .......
10000 98712.567
this format is not convenient to read.
can you hint me where the problem is and how can I make it back to the
first format?
I worked on this hours but still can not figure out.
any suggestions highly appreciated!
thank you
yong
More information about the R-help
mailing list