-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org]
On Behalf Of DL
Sent: Saturday, May 12, 2012 1:33 PM
To: r-help at r-project.org
Subject: [R] Help with writing data to csv
I am trying to write data to csv but I am having issues with the
separations.
Basically I have some results that I get with R that I copied and pasted
into word and then saved as .txt
I want to write the results to csv because it's easier to make tables in
word (all I would have to do is copy and paste into a table, instead of
typing everything out).
I am able to write the data to the .csv file but the data is not
comma-delimited when I open the file. Everything is written into the first
cell.
These are the various commands that I have been inputting:
write.csv(practice, file.choose(new=T), quote=F, row.names=F)
write.csv(practice, file.choose(new=T), sep=",", quote=F, row.names=F)
Warning message:
In write.csv(practice, file.choose(new = T), sep = ",", quote = F, :
attempt to set 'sep' ignored
write.table(practice, file =
"C:/Users/User/Documents/Documents/Proyectodeafroantillanos/Laterals/pract
ice.csv",
sep="\t", quote=F, row.names=F)
write.csv(practice, file =
"C:/Users/User/Documents/Documents/Proyectodeafroantillanos/Laterals/pract
ice.csv")
write.csv(practice, file =
"C:/Users/User/Documents/Documents/Proyectodeafroantillanos/Laterals/pract
ice.csv",
write.csv(practice, file =
"C:/Users/User/Documents/Documents/Proyectodeafroantillanos/Laterals/pract
ice.csv",
sep = "\t", row.names=FALSE)
Warning message:
In write.csv(practice, file =
"C:/Users/User/Documents/Documents/Proyectodeafroantillanos/Laterals/pract
ice.csv",
:
attempt to set 'sep' ignored
As you can see, the commands in which I write to csv and set "sep" I get a
message saying that attempt to set "sep" ignored. All the other commands
work but I don't get a comma-delimited nor a tab-delimited file.
Am I doing something wrong?
Thank you.