Skip to content

Instantly share code, notes, and snippets.

@goldingn
Last active August 29, 2015 14:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save goldingn/1eeccbeef42351276047 to your computer and use it in GitHub Desktop.
Save goldingn/1eeccbeef42351276047 to your computer and use it in GitHub Desktop.
Tweak RStudio desktop on OSX to put plots and docs in external windows
#!/bin/bash
# modify RStudio's options to send plots to quartz by default,
# and open help and local html in the default browser
echo "
# ~~~~~~~~~~~
# Tweaks to view help and html in the browser, and plots in quartz, not the RStudio viewer pane
browser <- '/usr/bin/open'
device <- 'quartz'
# pop out help in the default web browser
options(browser = browser)
# use the browser as the viewer
options(viewer = browser)
# use quartz to view figures
options(device = device)" >> /Applications/RStudio.app/Contents/Resources/R/Options.R
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment