I'm running Mac OS Maverick.
In my previous setup, the plots would correctly display on the plot tab on RStudio.
I reinstalled R with homebrew
and, when I use RStudio, it gives me the following warning
WARNING: The version of R you are running against does not support the quartz graphics device (which is required by RStudio for graphics). The Plots tab will be disabled until a version of R that supports quartz is installed.
When I plot something, it opens up the XQuartz
app on my mac. It does display the graphs (sometimes with weird colors though), but I'd really like it to plot in RStudio itself.
Is it that homebrew
has a version of R
that doesn't support the quartz graphics device or have I messed up something elsewhere?
As always, any help will be very much appreciated.
Some details of my setup:
R version 3.1.2 (2014-10-31) -- "Pumpkin Helmet"
RStudio Version 0.98.1091
Platform: x86_64-apple-darwin13.4.0 (64-bit). Mac OS 10.9.5
I installed R
with homebrew
the following way
brew tap homebrew/science
brew install r
Previously I had installed tcl/tk
the following way
brew tap homebrew/dupes
brew install tcl-tk --with-tk
I run into the same issue.
According to the R brew formula history the last bottled version (i.e. precompiled version, which is what is installed by default) isn't run against aqua due to some bug so the installation of R has no aqua capabilities, which is what RStudio graphics device requires.
After trying to understand the formula logic I figured that if built from source:
brew install r --build-from-source
it would compile with clang (check brew --env
) and therefore correctly build against aqua. It takes a little longer to install but it worked for me. To check, from the terminal open R and see capabilities()
aqua should be TRUE
for RStudio's graphics device to work.