Install and Configure R on Mac OS X

Have been changed to work on Mac OS X for a while with R, here is some documentation for configure R in Mac.

Install R with homebrew

Install the missing package management for OS X

1
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Then retrieve the caskroom for R binary installation:

1
brew install caskroom/cask/brew-cask

Then install R:

1
brew install Caskroom/cask/r

R configuration

Use a browser for R help document viewing:

  1. create a .rprofile in the home location
  2. add options(help_type = "html") in the .rprofile

Internalisation of R, run the code in terminal:

1
defaults write org.R-project.R force.LANG en_US.UTF-8