Re: [R] Writing specific columns to a data file

2009-04-07 Thread Peter Dalgaard
Coen van Hasselt wrote: By only selecting the first column, i.e. write.table(data[,1], file="", .) ? Notice that this drops to a vector, losing the variable name. Brendan may need data[,1, drop=FALSE], and/or give row.names=FALSE to write.table, depending on what the real problem was.

Re: [R] Writing specific columns to a data file

2009-04-06 Thread Coen van Hasselt
By only selecting the first column, i.e. write.table(data[,1], file="", .) ? On Tue, Apr 7, 2009 at 12:28, Brendan Morse wrote: > Hi, I have a function that generates some output with 2 columns, but I > only want to write the first column to a file. Is there a way to do > this in the write.t

[R] Writing specific columns to a data file

2009-04-06 Thread Brendan Morse
Hi, I have a function that generates some output with 2 columns, but I only want to write the first column to a file. Is there a way to do this in the write.table command? thetaout=write.table(estimatedtheta, file="/Users/morse07/Desktop/R/ Trial/score.dat", row.names=F, col.names=F) Any adv

[R] Writing specific columns to a data file

2009-04-06 Thread Brendan Morse
Hi, I have a function that generates some output with 2 columns, but I only want to write the first column to a file. Is there a way to do this in the write.table command? thetaout=write.table(estimatedtheta, file="/Users/morse07/Desktop/R/ Trial/score.dat", row.names=F, col.names=F) Any adv