rstan icon indicating copy to clipboard operation
rstan copied to clipboard

Error messages when running example(stan_model, package = "rstan", run.dontrun = TRUE)

Open ndcn0002 opened this issue 2 years ago • 2 comments

Hi All,

I'm new to rstan. I just installed rstan by:

  install.packages("rstan", repos = c("https://mc-stan.org/r-packages/", getOption("repos")))

Once it was installed, I loaded libraries StanHeaders and rstan

  library(StanHeaders)
  library(rstan)

Then I ran:

  example(stan_model, package = "rstan", run.dontrun = TRUE)

which gave me a lot of messages (400 lines) which ended with the following:

  Compilation ERROR, function(s)/method(s) not created!
  Error in compileCode(f, code, language = language, verbose = verbose) : 
  Error in system(paste(MAKE, p1(paste("-f", shQuote(makefiles))), "compilers"),  :   'make' not foundCalls: <Anonymous> -> 
  .shlib_internal -> systemExecution halted

So I assumed I did something wrong or missed some installation steps. Any advice would be very much appreciated

Thanks!

ndcn0002 avatar Nov 13 '23 02:11 ndcn0002

Maybe you should install rstan following this website https://github.com/stan-dev/rstan/wiki/RStan-Getting-Started

ChenghuFeng avatar Nov 13 '23 13:11 ChenghuFeng

If you still have problems, try these instructions: https://discourse.mc-stan.org/t/rstan-2-30/30415/2?u=rosgori

rosgori avatar Dec 24 '23 03:12 rosgori