Giter VIP home page Giter VIP logo

xbart's Introduction

To install in R library(devtools) install_github("JingyuHe/XBART")

For mac users seeing error clang: error: unsupported option '-fopenmp'

It is because the default C++ compiler on Mac does not support openmp.

To solve it

  1. Install necessary packages via homebrew

    brew cask install gfortran

    brew install llvm boost libomp

    brew info llvm See what the LDFLAGS is, mine is like: LDFLAGS=β€œ-L/opt/homebrew/opt/llvm/lib -Wl,-rpath,/opt/homebrew/opt/llvm/lib”

  2. Run the following code in the terminal, under your user directory (/Users/your_user_name)

    mkdir -p ~/.R

    cd .R

    touch Makevars

    open -e Makevars

  3. Then the text editor pops out, copy and paste the following lines to the file

    CC=/opt/homebrew/opt/llvm/lclang CXX=/opt/homebrew/opt/llvm/clang++ CXX11=/opt/homebrew/opt/llvm/clang++ CXX14=/opt/homebrew/opt/llvm/clang++ CXX17=/opt/homebrew/opt/llvm/clang++ CXX1X=/opt/homebrew/opt/llvm/clang++ LDFLAGS=-L/opt/homebrew/opt/llvm/lib

  4. Save, exit and reboot your Mac

xbart's People

Contributors

jingyuhe avatar saaryalov avatar maggiewang0614 avatar jmurray1022 avatar prhahn avatar leereeves avatar danmerl avatar socket778 avatar naeemkh avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.