Hi, I am new to R. I am using spatstat package to generate some sample points but don't know how to save the result to file. Could anyone please give me some instructions? Thanks I generate some random point data by using: pp<-runifpoint(100) I can plot it out with plot(pp) I suppose that pp contains x and y. How can I save these x, y pairs to file that has following format? x1,y1 x2,y2 ... ... ... Thanks again Steve _________________________________________________________________ Get Free (PRODUCT) REDâ„¢ Emoticons, Winks and Display Pics. [[alternative HTML version deleted]]
On 09/05/2008 5:55 PM, mtrp mtrp wrote:> Hi, > I am new to R. I am using spatstat package to generate some sample points but don't know how to save the result to file. Could anyone please give me some instructions? Thanks > > I generate some random point data by using: > pp<-runifpoint(100) > I can plot it out with plot(pp) > I suppose that pp contains x and y. How can I save these x, y pairs to file that has following format? > x1,y1 > x2,y2 > ...write.csv(cbind(pp$x, pp$y), file="my.file") should do it. Duncan Murdoch