sessionInfo() R version 3.3.1 (2016-06-21) ...">

Rstudio suddenly stopped showing plot graphics

Instead, they open in a separate file named "Quartz"

> sessionInfo() R version 3.3.1 (2016-06-21) Platform: x86_64-apple-darwin13.4.0 (64-bit) Running under: OS X 10.9.5 (Mavericks) locale: [1] en_CA.UTF-8/en_CA.UTF-8/en_CA.UTF-8/C/en_CA.UTF-8/en_CA.UTF-8 attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] cluster_2.0.4 tm_0.6-2 NLP_0.1-9 ggplot2_2.1.0 loaded via a namespace (and not attached): [1] colorspace_1.2-6 scales_0.4.0 plyr_1.8.4 parallel_3.3.1 tools_3.3.1 gtable_0.2.0 Rcpp_0.12.5 slam_0.1-35 [9] grid_3.3.1 munsell_0.4.3 

I tried tools> global options> panels> selected areas.

I do not know what other information you want to share. I see the plot area with the "Charts" tab active. But it is empty.

Screen: enter image description here

Notice that a new menu appears with the words "Quartz". Not sure what it is, but it appears when r generates a graph and the regular rstudio menu disappears.

How can I show rstudio to display graphs in the graph panel, as it was done 5 minutes ago?

+8
source share
7 answers

Try to do this.

 dev.off() 

See if it works

 plot(rnorm(50), rnorm(50)) 
+8
source

I work with Rmarkdown, and in my case, I solved this problem as follows:

  • Go to Tools-> Global Settings-> Rmarkdown

  • In the "Show preview in window" section, select "View Panel"

  • Uncheck "Show output lines for all R Markdown documents"

All the best!

+4
source

it worked for me when I first closed all @ udit-gupta devices. Recursively close all devices after device discovery.

 dev.cur() dev.off(i) #where i = index of device to be switched off 

return device with

 getOption("device") 

or

 dev.set(which = dev.next()) 
+4
source

I had the same problem after updating R to version 3.3.2 and using Rstudio 0.98.0. Installing the latest version of RStudio fixed the problem

+3
source

If the same problem ... was able to visualize graphs in the graph area some time before it disappeared ... all attempts with the suggestions above failed ... they sent out a blog below and made it work ...

https://datasciencelearner.wordpress.com/2014/08/17/my-plot-is-not-showing-up/

the trick is to wrap the graphic command inside the print function ... for example ...

 print( plt2 <- ggplot(housing, aes(x = Home.Value)) + geom_histogram() ) 
+2
source

This may be due to the fact that the graphics device is already on.

To find open device indices: dev.cur() close dev.off(i) devices

whereas i = the index of the device to be disconnected

+1
source

To resolve the problem, follow the procedure below.

  dev.off() print(plot(1)) # Basically use print command once 

Now use the plot command, as you usually use, and it should work fine.

0
source

All Articles