I am having trouble getting my graphs to appear in the 'plots' window of R studio - once I run the script they appear in a separate R graphics window, separate to R Studio, with the 'plots' tab blank. when i use
dev.off()
it gives the error
*error in dev.off(): cannot shut down device 1 (the null device)*
Even if i ran this command twice the error still there. I tried restart Rstudio- did not work