Hello the following simple model
library(rstan)
bb_model <-"
data {
int Y;
int N;
}
parameters {
real pi;
}
model {
Y ~ binomial(N, pi);
pi ~ beta(2, 2);
}
"
bb_sim ←
stan(
model_code = bb_model,
data = list(N = 10, Y = 9),
chains = 4,
iter = 1e3 * 2
)
gives this output
make cmd is
make -f “C:/PROGRA~1/R/R-43~1.1/etc/x64/Makeconf” -f “C:/PROGRA~1/R/R-43~1.1/share/make/winshlib.mk” CXX=‘(CXX14) (CXX14STD)’ CXXFLAGS=‘(CXX14FLAGS)' CXXPICFLAGS='(CXX14PICFLAGS)’ SHLIB_LDFLAGS=‘(SHLIB_CXX14LDFLAGS)' SHLIB_LD='(SHLIB_CXX14LD)’ SHLIB=“file1a28df63317.dll” WIN=64 TCLBIN= OBJECTS=“file1a28df63317.o”
make would use
if test “zfile1a28df63317.o” != “z”; then
if test -e “file1a28df63317-win.def”; then
echo g++ -shared -s -static-libgcc -o file1a28df63317.dll file1a28df63317-win.def file1a28df63317.o -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib/x64" -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib" -L"C:/PROGRA~1/R/R-43~1.1/bin/x64" -lR ;
g++ -shared -s -static-libgcc -o file1a28df63317.dll file1a28df63317-win.def file1a28df63317.o -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib/x64" -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib" -L"C:/PROGRA~1/R/R-43~1.1/bin/x64" -lR ;
else
echo EXPORTS > tmp.def;
nm file1a28df63317.o | sed -n ‘s/^.* [BCDRT] / /p’ | sed -e ‘/[.]refptr[.]/d’ -e ‘/[.]weak[.]/d’ | sed ‘s/[^ ][^ ]*/“&”/g’ >> tmp.def;
echo g++ -shared -s -static-libgcc -o file1a28df63317.dll tmp.def file1a28df63317.o -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib/x64" -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib" -L"C:/PROGRA~1/R/R-43~1.1/bin/x64" -lR ;
g++ -shared -s -static-libgcc -o file1a28df63317.dll tmp.def file1a28df63317.o -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib/x64" -L"C:/rtools43/x86_64-w64-mingw32.static.posix/lib" -L"C:/PROGRA~1/R/R-43~1.1/bin/x64" -lR ;
rm -f tmp.def;
fi
fi
Error in compileCode(f, code, language = language, verbose = verbose) :
C:\rtools43\x86_64-w64-mingw32.static.posix\bin/ld.exe: file1a28df63317.o:file1a28df63317.cpp:(.text$_ZN3tbb8internal26task_scheduler_observer_v3D0Ev[_ZN3tbb8internal26task_scheduler_observer_v3D0Ev]+0x1c): undefined reference to tbb::internal::task_scheduler_observer_v3::observe(bool)'C:\rtools43\x86_64-w64-mingw32.static.posix\bin/ld.exe: file1a28df63317.o:file1a28df63317.cpp:(.text$_ZN3tbb10interface623task_scheduler_observerD1Ev[_ZN3tbb10interface623task_scheduler_observerD1Ev]+0x1c): undefined reference to
tbb::internal::task_scheduler_observer_v3::observe(bool)'C:\rtools43\x86_64-w64-mingw32.static.posix\bin/ld.exe: file1a28df63317.o:file1a28df63317.cpp:(.text$_ZN3tbb10interface623task_scheduler_observerD1Ev[_ZN3tbb10interface623task_scheduler_observerD1Ev]+0x37): undefined reference to `tbb::internal::task_scheduler_observer_v3::observe(bool)'C:\rtools43\x86_64-w64-mingw32.static.posix\bin/ld.exe: file1a28df63317.o:file1a28df63317.cpp:(.text$ZN3tbb10interface623task
Error in sink(type = “output”) : invalid connection