Hi all,
I am looking to execute some bayesian multilevel models in R. I have the rstan, rstanheaders, and rstantools installed, as well as rtools 43, and R version 4.2.3 (2023-03-15 ucrt). My model code is pictured below.
fit.brm <- brm(formula = unidirectional_psyP ~ 1 + alc_gm_center + Female_d +
alc_b4_unipsyP.c + AvgSeeNA.c + alc_b4_unipsyP.c:AvgSeeNA.c +
(1|ID1),
family = bernoulli(link = "logit"),
data = data.prep,
cores = 2)
When I run this model, the following information in my R console.
Compiling Stan program...
make cmd is
make -f "C:/PROGRA~1/R/R-42~1.3/etc/x64/Makeconf" -f "C:/PROGRA~1/R/R-42~1.3/share/make/winshlib.mk" CXX='$(CXX14) $(CXX14STD)' CXXFLAGS='$(CXX14FLAGS)' CXXPICFLAGS='$(CXX14PICFLAGS)' SHLIB_LDFLAGS='$(SHLIB_CXX14LDFLAGS)' SHLIB_LD='$(SHLIB_CXX14LD)' SHLIB="file71703b4e360a.dll" WIN=64 TCLBIN= OBJECTS="file71703b4e360a.o"
make would use
Warning message:
In system(paste(cmd, "-n")) : 'make' not found
Error in compileCode(f, code, language = language, verbose = verbose) :
Warning message:In system(cmd) : 'make' not found
In addition: Warning message:
Rows containing NAs were excluded from the model.
Error in sink(type = "output") : invalid connection
I have searched this issue extensively, and have re-installed Rstan and RstanHeaders from the source. I also re-installed Rtools. I’d appreciate any help with this!!
Here is some additional output from diagnostics I was running in case it would help.
> Sys.getenv("PATH")
[1] "C:\\Users\\tjsha\\AppData\\Local\\Programs\\Python\\Python311\\Scripts;C:\\Users\\tjsha\\AppData\\Local\\Programs\\Python\\Python311;C:\\rtools42\\x86_64-w64-mingw32.static.posix\\bin;C:\\rtools42\\usr\\bin;C:\\Program Files\\R\\R-4.2.3\\bin\\x64;C:\\Program Files (x86)\\Intel\\oneAPI\\tbb\\2021.9.0\\redist\\intel64\\vc_mt;C:\\Program Files (x86)\\Intel\\oneAPI\\tbb\\2021.9.0\\redist\\ia32\\vc_mt;C:\\Program Files (x86)\\Intel\\oneAPI\\compiler\\2023.1.0\\windows\\redist\\intel64_win\\compiler;C:\\Program Files (x86)\\Intel\\oneAPI\\compiler\\2023.1.0\\windows\\redist\\ia32_win\\compiler;C:\\Windows\\System32;C:\\Windows;C:\\Windows\\System32\\wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0;C:\\Windows\\System32\\OpenSSH;C:\\Program Files (x86)\\NVIDIA Corporation\\PhysX\\Common;C:\\Program Files\\NVIDIA Corporation\\NVIDIA NvDLISR;C:\\Program Files\\dotnet;C:\\Program Files (x86)\\Pulse Secure\\VC142.CRT\\X64;C:\\Program Files (x86)\\Pulse Secure\\VC142.CRT\\X86;C:\\Program Files\\MATLAB\\R2022b\\bin;C:\\Program Files (x86)\\Common Files\\Pulse Secure\\TNC Client Plugin;C:\\Program Files\\Git\\cmd;C:\\Windows\\System32;C:\\Windows;C:\\Windows\\System32\\wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0;C:\\Windows\\System32\\OpenSSH;C:\\Program Files\\MySQL\\MySQL Shell 8.0\\bin;C:\\Users\\tjsha\\AppData\\Local\\Microsoft\\WindowsApps;C:\\Users\\tjsha\\AppData\\Local\\Programs\\Microsoft VS Code\\bin;C:\\Program Files\\RStudio\\resources\\app\\bin\\quarto\\bin;C:\\Program Files\\RStudio\\resources\\app\\bin\\postback"
Sys.getenv("RTOOLS43_HOME")
[1] "C:\\rtools43"
Version info:
brms * 2.19.0 2023-03-14 [1] CRAN (R 4.2.3)
devtools * 2.4.5 2022-10-11 [1] CRAN (R 4.2.3)
rstan * 2.26.23 2023-09-08 [1] CRAN (R 4.2.3)
rstantools 2.3.1.1 2023-07-18 [1] CRAN (R 4.2.3)
StanHeaders * 2.26.28 2023-09-07 [1] CRAN (R 4.2.3)