Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in RStudioGD() : Shadow graphics device error: r error 4 (R code execution error) #2214

Closed
ArRstudio opened this issue Feb 16, 2018 · 5 comments

Comments

@ArRstudio
Copy link

@ArRstudio ArRstudio commented Feb 16, 2018

System details

RStudio Edition : <!-- Desktop or Server -->
RStudio Version : Version 1.0.136
OS Version      : ubuntu
R Version       : 3.3.3

Steps to reproduce the problem

plot(cars)
Error in RStudioGD() : Shadow graphics device error: r error 4 (R code execution error) In addition: Warning message: In grDevices:::png("/tmp/RtmpEdEj7l/642098b8481c4db7820081c92f4117e7.png", : unable to open connection to X11 display ''

 

| >

Describe the problem in detail

i am trying to run plot(cars) on rstudio application ,receiving this below error

plot(cars)
Error in RStudioGD() : Shadow graphics device error: r error 4 (R code execution error) In addition: Warning message: In grDevices:::png("/tmp/RtmpEdEj7l/642098b8481c4db7820081c92f4117e7.png", : unable to open connection to X11 display ''

 

| >

Describe the behavior you expected

@ronblum

This comment has been minimized.

Copy link

@ronblum ronblum commented Feb 19, 2018

@ArRstudio Are you able to run plot(cars) successfully in R alone, outside of RStudio? Also, you might consider updating to the latest version of RStudio, 1.1.423, which is available for download at https://www.rstudio.com/products/rstudio/download/

@ronblum

This comment has been minimized.

Copy link

@ronblum ronblum commented Feb 20, 2018

@ArRstudio It looks like this is being handled by our professional Support Team (issue 25469) so I'm am going to close it in this queue.

@ronblum ronblum closed this Feb 20, 2018
@dfalty dfalty added the verified label Feb 22, 2018
@andzandz11

This comment has been minimized.

Copy link

@andzandz11 andzandz11 commented Feb 25, 2019

Same issue here:


> plot(mtcars)
Error in RStudioGD() : 
  Shadow graphics device error: r error 4 (R code execution error)
In addition: Warning messages:
1: In grDevices:::png("C:/Users/gf1954/AppData/Local/Temp/Rtmp02Ep26/1033921b18d7481796b9759f3bc1e62b.png",  :
  kann Datei 'C:/Users/gf1954/AppData/Local/Temp/Rtmp02Ep26/1033921b18d7481796b9759f3bc1e62b.png' nicht zum Schreiben öffnen
2: In grDevices:::png("C:/Users/gf1954/AppData/Local/Temp/Rtmp02Ep26/1033921b18d7481796b9759f3bc1e62b.png",  :
  opening device failed

Another RStudio instance works but this instance fails.

@Rietaros

This comment has been minimized.

Copy link

@Rietaros Rietaros commented May 7, 2019

I use RStudio Version 1.1.463 – © 2009-2018 RStudio, Windows 10

have the same issue
Error in RStudioGD() : Shadow graphics device error: r error 4 (R code execution error) In addition: Warning messages: 1: In grDevices:::png("C:/Users/AFITRI~1/AppData/Local/Temp/RtmpQBGjX0/01f79ba1aad74fd3b5c52d0423bda7af.png", : unable to open file 'C:/Users/AFITRI~1/AppData/Local/Temp/RtmpQBGjX0/01f79ba1aad74fd3b5c52d0423bda7af.png' for writing 2: In grDevices:::png("C:/Users/AFITRI~1/AppData/Local/Temp/RtmpQBGjX0/01f79ba1aad74fd3b5c52d0423bda7af.png", : opening device failed

@kevinushey

This comment has been minimized.

Copy link
Contributor

@kevinushey kevinushey commented May 20, 2019

The error most likely implies that RStudio / your user account does not have write access to your Temp folder for some reason. Unfortunately figuring out why this is the case could be very challenging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
6 participants
You can’t perform that action at this time.