How to convert .Rdata format into text file format

Teja picture Teja · Nov 2, 2012 · Viewed 35.4k times · Source

I am a novice in R and I am trying to convert .Rdata format file into comma delimited text file format. Can someone help me out regarding this?

Answer

Chase picture Chase · Nov 2, 2012
load("yourData.RData")
ls() #returns a list of all the objects you just loaded (and anything else in your environment)
write.csv(theItemOfInterestFromYourDRadataFileAsThereMayBeMoreThanOneThingInthere,
  file="yourCSV.csv")