Namespace and not found when load "rstan" library


when i installed rstan then include all dependencies, after installation restart R and load rstan library.
when i was trying to load rstan library then it’s give a error


Session info


Thanks for moving the discussion over here from the issue. (I don’t know the answer, or I would’ve included it there.)



then restart R making sure that no old stanfit objects are being autoloaded at startup and do



I followed steps suggested by you
now rstan package not installed agian
Give error

When i installed this then follow this url and create Makevars file now it give error in that file.

Please help me i’m stuck in this issue very badly and i spend 2-3 days on this issue.
I want used prophet package for time series and rstan is dependencies for that package :( :(


What does your file at ~/.R/Makevars contain?

In .R folder has a Makevars file which is contain r command

dotR <- file.path(Sys.getenv(“HOME”), “.R”)
if (!file.exists(dotR)) dir.create(dotR)
M <- file.path(dotR, “Makevars”)
if (!file.exists(M)) file.create(M)

Eliminate all that (which is R code you were supposed to call to create the Makevars file) and paste in

CXXFLAGS=-O3 -mtune=native -march=native -Wno-unused-variable -Wno-unused-function  -Wno-macro-redefined