Articles

Affichage des articles du décembre, 2020

Setup new installation of R in MacosX

Adapted from  https://ryanhomer.github.io/posts/build-openmp-macos-catalina-complete Install R from  cran.r-project.org At the end of ~/.zshrc add:  export PATH=$PATH:/Library/Frameworks/R.framework/Versions/Current/Resources/bin/ Then you can use R within the terminal. Install macbrew via: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" Then in ~/.Rprofile: marcgirondot@MacBook-Pro-de-Marc ~ % cat .Rprofile # Default CRAN mirror options(repos=structure(c(CRAN="https://cloud.r-project.org/"))) # Path to run R with system Sys.setenv(PATH=paste(Sys.getenv("PATH"), "/Library/Frameworks/R.framework/Versions/Current/Resources/bin/", sep=":")) Install llvm brew install llvm libomp Install GCC and gettext brew install gcc gettext To configure R to build packages with the versions of clang and gcc you just installed, set up a Makevars file. This must be located at ~/.r/Makevars. Some parts do no w