[R] write.csv and col.names=F

Gabor Grothendieck ggrothendieck at gmail.com
Fri Dec 18 13:30:03 CET 2009


Use write.table instead.

On Thu, Dec 17, 2009 at 6:52 PM, kayj <kjaja27 at yahoo.com> wrote:
>
> Hi All,
>
> I always have a problem with write.csv when I want the column names to be
> ignored, when I specify col.names=F, I get a header of V1 V2 V3 V4 etc.
>
> for example I tried
>
> write.csv(mydata, file="data.csv", quote=FALSE, row.names=F, col.names=F)
> Warning message:
> In write.csv(mydata, file = "data.csv", quote = FALSE,  :
>  attempt to set 'col.names' ignored
>>
>
> how can I get rid of this problem ? I do not want the header of V1 V2 V3...
> to appear in my output file,
>
> Thanks
> --
> View this message in context: http://n4.nabble.com/write-csv-and-col-names-F-tp974477p974477.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> 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.
>




More information about the R-help mailing list