I  first I saved the following commands in a whatever.r file.

data<-read.csv(file="whatever.csv", head=TRUE, sep=",")
summary(data$SQFT)
hist(data$STAMP)
hist(data$STAMP, col='blue')
hist(data$SHIP, col='blue')

then I clicked File Menu-> source and chose  whatever.r, it runs the
commands and produces the histograms and stuff.
then I did
sink("comm.docx")
sink()

It creates an empty file "comm.docx". Now my problem is that I want to run
the commands in whatever.r file( this part is working )  and then save the
output(has graphs hists etc) in a file.

How do I do that ? Your help will be greatly appreciated!!

Gagan

        [[alternative HTML version deleted]]

______________________________________________
R-help@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.

Reply via email to