Re: [R] repeat write.table with the same code many times

2010-11-30 Thread Joshua Wiley
Hi Laura, I'm a little weak on my use of connections, but I wonder if something like this would not be a better option. As I understand it, using write.table() with append = TRUE is a slow way to many lines to a file. ## create a writable connection to a file gt <- file("bootstrap_results.txt",

Re: [R] repeat write.table with the same code many times

2010-11-30 Thread James W. MacDonald
Hi Laura, On 11/30/2010 9:57 AM, Laura Bonnett wrote: Dear all, I am using R version 2.9.2 in Windows. I would like to output the results of a function I have written to a .txt file. I know that I can do this by using the code write.table(boothd(10),"boothd10.txt",sep="\t",append=TRUE) etc.

Re: [R] repeat write.table with the same code many times

2010-11-30 Thread jim holtman
Try using a connection: output <- file('boothd10.txt", 'w') write.table(boothd(10), output, sep = '\t', col.names = FALSE) close(output) On Tue, Nov 30, 2010 at 9:57 AM, Laura Bonnett wrote: > Dear all, > > I am using R version 2.9.2 in Windows. > > I would like to output the results of a

[R] repeat write.table with the same code many times

2010-11-30 Thread Laura Bonnett
Dear all, I am using R version 2.9.2 in Windows. I would like to output the results of a function I have written to a .txt file. I know that I can do this by using the code write.table(boothd(10),"boothd10.txt",sep="\t",append=TRUE) etc. However, I would like to bootstrap my function 'boothd' s