forked from stan-dev/rstan
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall_StanHeaders.R
More file actions
13 lines (12 loc) · 858 Bytes
/
install_StanHeaders.R
File metadata and controls
13 lines (12 loc) · 858 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
# It is easiest to install StanHeaders from CRAN via install.packages("StanHeaders")
# You only need this script if you want to install the develop (or some other) branch of StanHeaders,
# including its submodules. This requires the git2r and devtools packages
path_rstan <- tempfile(pattern = "git2r-")
git2r::clone("http://github.com/stan-dev/rstan", path_rstan, branch = "develop")
git2r::clone("http://github.com/stan-dev/stan",
file.path(path_rstan, "StanHeaders", "inst", "include", "upstream"),
branch = "develop") # may want to change this branch
git2r::clone("http://github.com/stan-dev/math",
file.path(path_rstan, "StanHeaders", "inst", "include", "mathlib"),
branch = "develop") # may want to change this branch
devtools::install(file.path(path_rstan, "StanHeaders"), args = "--preclean")