It seems like the stan_surv function is not included in the latest rstanarm binary, so I’m trying to install the feature/survival branch from github. The installation is failing, and I’m not sure what else to try.
I’m using Mac Monterey 12.4, and R 4.2.1. Here are the warning and error messages I’m getting. The warning messages are repetitive and exceeding the character limit for the post, so I cut out some of them out. Any help would be much appreciated!
> remotes::install_github('stan-dev/rstanarm@feature/survival', dependencies = TRUE, build_vignettes = FALSE)
Downloading GitHub repo stan-dev/rstanarm@feature/survival
Skipping 2 packages ahead of CRAN: StanHeaders, rstan
✔ checking for file ‘/private/var/folders/59/4rn659ld3tzgzyzbnglmvnqw0000gp/T/Rtmph6l7tx/remotes55657b4baf0c/stan-dev-rstanarm-daa4303/DESCRIPTION’ ...
─ preparing ‘rstanarm’:
✔ checking DESCRIPTION meta-information ...
─ cleaning src
─ running ‘cleanup’
─ checking for LF line-endings in source and make files and shell scripts
─ checking for empty or unneeded directories
─ building ‘rstanarm_2.21.2.tar.gz’
* installing *source* package ‘rstanarm’ ...
** using staged installation
** libs
"/Library/Frameworks/R.framework/Resources/bin/Rscript" -e "source(file.path('..', 'tools', 'make_cc.R')); make_cc(commandArgs(TRUE))" stan_files/bernoulli.stan
Wrote C++ file "stan_files/bernoulli.cc"
clang++ -mmacosx-version-min=10.13 -std=gnu++14 -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I"../inst/include" -I"/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src" -DBOOST_DISABLE_ASSERTS -DEIGEN_NO_DEBUG -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include' -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include' -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/BH/include' -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/Rcpp/include' -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include' -I'/Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppParallel/include' -I/usr/local/include `"/Library/Frameworks/R.framework/Resources/bin/Rscript" -e "RcppParallel::CxxFlags()"` `"/Library/Frameworks/R.framework/Resources/bin/Rscript" -e "StanHeaders:::CxxFlags()"` -fPIC -Wall -g -O2 -c stan_files/bernoulli.cc -o stan_files/bernoulli.o
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/Eigen.hpp:22:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/Dense:1:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/Core:540:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/src/Core/util/ReenableStupidWarnings.h:14:30: warning: pragma diagnostic pop could not pop, no matching push [-Wunknown-pragmas]
#pragma clang diagnostic pop
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:3:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/Eigen.hpp:22:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/Dense:2:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/LU:47:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/RcppEigen/include/Eigen/src/Core/util/ReenableStupidWarnings.h:14:30: warning: pragma diagnostic pop could not pop, no matching push [-Wunknown-pragmas]
#pragma clang diagnostic pop
^
...
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:48:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_base.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core.hpp:28:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_addition.hpp:84:43: warning: lambda capture 'b' is not used [-Wunused-lambda-capture]
[avi = a.vi_, b](const auto& vi) mutable {
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/trigamma.hpp:63:31: note: in instantiation of function template specialization 'stan::math::operator+<double, nullptr>' requested here
value = -trigamma_impl(-x + 1.0) + square(pi() / sin(-pi() * x));
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/fun/trigamma.hpp:23:44: note: in instantiation of function template specialization 'stan::math::trigamma_impl<stan::math::var_value<double>>' requested here
inline var trigamma(const var& u) { return trigamma_impl(u); }
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:23:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_header.hpp:15:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/indexing.hpp:9:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/indexing/rvalue.hpp:140:14: warning: unused variable 'v_size' [-Wunused-variable]
const auto v_size = v.size();
^
stan_files/bernoulli.hpp:5120:13: note: in instantiation of function template specialization 'stan::model::rvalue<Eigen::Matrix<double, -1, 1, 0> &, nullptr>' requested here
rvalue(smooth_sd,
^
stan_files/bernoulli.hpp:6109:7: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::write_array_impl<boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>, std::__1::vector<double>, std::__1::vector<int>, std::__1::vector<double>, nullptr, nullptr, nullptr>' requested here
write_array_impl(base_rng, params_r, params_i, vars, emit_transformed_parameters, emit_generated_quantities, pstream);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/io/random_var_context.hpp:77:11: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::write_array<boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
model.write_array(rng, unconstrained_params_, int_params,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/util/initialize.hpp:93:36: note: in instantiation of function template specialization 'stan::io::random_var_context::random_var_context<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
stan::io::random_var_context random_context(model, rng, init_radius,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/diagnose/diagnose.hpp:49:43: note: in instantiation of function template specialization 'stan::services::util::initialize<true, model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
std::vector<double> cont_vector = util::initialize(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:481:45: note: in instantiation of function template specialization 'stan::services::diagnose::diagnose<model_bernoulli_namespace::model_bernoulli>' requested here
return_code = stan::services::diagnose::diagnose(model,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:1215:11: note: in instantiation of function template specialization 'rstan::(anonymous namespace)::command<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
ret = command(args, model_, holder, names_oi_tidx_,
^
stan_files/bernoulli.cc:13:87: note: in instantiation of member function 'rstan::stan_fit<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>::call_sampler' requested here
.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:48:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_base.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core.hpp:29:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_divide_equal.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_division.hpp:15:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_subtraction.hpp:113:43: warning: lambda capture 'a' is not used [-Wunused-lambda-capture]
[bvi = b.vi_, a](const auto& vi) mutable {
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/ub_constrain.hpp:77:13: note: in instantiation of function template specialization 'stan::math::operator-<double, nullptr>' requested here
return ub - exp(x);
^
stan_files/bernoulli.hpp:3915:25: note: in instantiation of function template specialization 'stan::math::ub_constrain<stan::math::var_value<double>, double>' requested here
stan::math::ub_constrain(gamma[(sym1__ - 1)],
^
stan_files/bernoulli.hpp:6121:14: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob_impl<true, true, std::__1::vector<stan::math::var_value<double>>, std::__1::vector<int>, nullptr, nullptr>' requested here
return log_prob_impl<propto__, jacobian__>(params_r, params_i, pstream);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/log_prob_grad.hpp:40:36: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob<true, true, stan::math::var_value<double>>' requested here
var adLogProb = model.template log_prob<propto, jacobian_adjust_transform>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/util/initialize.hpp:166:31: note: in instantiation of function template specialization 'stan::model::log_prob_grad<true, true, model_bernoulli_namespace::model_bernoulli>' requested here
log_prob = stan::model::log_prob_grad<true, Jacobian>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/diagnose/diagnose.hpp:49:43: note: in instantiation of function template specialization 'stan::services::util::initialize<true, model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
std::vector<double> cont_vector = util::initialize(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:481:45: note: in instantiation of function template specialization 'stan::services::diagnose::diagnose<model_bernoulli_namespace::model_bernoulli>' requested here
return_code = stan::services::diagnose::diagnose(model,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:1215:11: note: in instantiation of function template specialization 'rstan::(anonymous namespace)::command<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
ret = command(args, model_, holder, names_oi_tidx_,
^
stan_files/bernoulli.cc:13:87: note: in instantiation of member function 'rstan::stan_fit<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>::call_sampler' requested here
.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:48:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_base.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core.hpp:29:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_divide_equal.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_division.hpp:15:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/operator_subtraction.hpp:113:43: warning: lambda capture 'a' is not used [-Wunused-lambda-capture]
[bvi = b.vi_, a](const auto& vi) mutable {
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/ub_constrain.hpp:77:13: note: in instantiation of function template specialization 'stan::math::operator-<int, nullptr>' requested here
return ub - exp(x);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/fun/lub_constrain.hpp:107:12: note: in instantiation of function template specialization 'stan::math::ub_constrain<stan::math::var_value<double>, int>' requested here
return ub_constrain(x, ub, lp);
^
stan_files/bernoulli.hpp:4110:25: note: in instantiation of function template specialization 'stan::math::lub_constrain<stan::math::var_value<double>, int, int, stan::math::var_value<double>>' requested here
stan::math::lub_constrain(rho[(sym1__ - 1)], 0, 1, lp__),
^
stan_files/bernoulli.hpp:6121:14: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob_impl<true, true, std::__1::vector<stan::math::var_value<double>>, std::__1::vector<int>, nullptr, nullptr>' requested here
return log_prob_impl<propto__, jacobian__>(params_r, params_i, pstream);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/log_prob_grad.hpp:40:36: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob<true, true, stan::math::var_value<double>>' requested here
var adLogProb = model.template log_prob<propto, jacobian_adjust_transform>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/util/initialize.hpp:166:31: note: in instantiation of function template specialization 'stan::model::log_prob_grad<true, true, model_bernoulli_namespace::model_bernoulli>' requested here
log_prob = stan::model::log_prob_grad<true, Jacobian>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/diagnose/diagnose.hpp:49:43: note: in instantiation of function template specialization 'stan::services::util::initialize<true, model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
std::vector<double> cont_vector = util::initialize(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:481:45: note: in instantiation of function template specialization 'stan::services::diagnose::diagnose<model_bernoulli_namespace::model_bernoulli>' requested here
return_code = stan::services::diagnose::diagnose(model,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:1215:11: note: in instantiation of function template specialization 'rstan::(anonymous namespace)::command<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
ret = command(args, model_, holder, names_oi_tidx_,
^
stan_files/bernoulli.cc:13:87: note: in instantiation of member function 'rstan::stan_fit<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>::call_sampler' requested here
.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:23:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_header.hpp:15:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/indexing.hpp:9:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/indexing/rvalue.hpp:140:14: warning: unused variable 'v_size' [-Wunused-variable]
const auto v_size = v.size();
^
stan_files/bernoulli.hpp:4324:13: note: in instantiation of function template specialization 'stan::model::rvalue<Eigen::Matrix<stan::math::var_value<double>, -1, 1, 0> &, nullptr>' requested here
rvalue(smooth_sd,
^
stan_files/bernoulli.hpp:6121:14: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob_impl<true, true, std::__1::vector<stan::math::var_value<double>>, std::__1::vector<int>, nullptr, nullptr>' requested here
return log_prob_impl<propto__, jacobian__>(params_r, params_i, pstream);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/log_prob_grad.hpp:40:36: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob<true, true, stan::math::var_value<double>>' requested here
var adLogProb = model.template log_prob<propto, jacobian_adjust_transform>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/util/initialize.hpp:166:31: note: in instantiation of function template specialization 'stan::model::log_prob_grad<true, true, model_bernoulli_namespace::model_bernoulli>' requested here
log_prob = stan::model::log_prob_grad<true, Jacobian>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/diagnose/diagnose.hpp:49:43: note: in instantiation of function template specialization 'stan::services::util::initialize<true, model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
std::vector<double> cont_vector = util::initialize(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:481:45: note: in instantiation of function template specialization 'stan::services::diagnose::diagnose<model_bernoulli_namespace::model_bernoulli>' requested here
return_code = stan::services::diagnose::diagnose(model,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:1215:11: note: in instantiation of function template specialization 'rstan::(anonymous namespace)::command<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
ret = command(args, model_, holder, names_oi_tidx_,
^
stan_files/bernoulli.cc:13:87: note: in instantiation of member function 'rstan::stan_fit<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>::call_sampler' requested here
.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:48:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_base.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core.hpp:52:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/precomputed_gradients.hpp:83:59: warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
container_operands_(index_apply<N_containers>([&, this](auto... Is) {
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/functor/operands_and_partials.hpp:167:16: note: in instantiation of function template specialization 'stan::math::precomputed_gradients_vari_template<std::__1::tuple<>, std::__1::tuple<>>::precomputed_gradients_vari_template<>' requested here
return new precomputed_gradients_vari_template<
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/prim/prob/bernoulli_logit_glm_lpmf.hpp:166:23: note: in instantiation of member function 'stan::math::operands_and_partials<const Eigen::Matrix<double, -1, -1, 0> &, const stan::math::var_value<double> &, const Eigen::Matrix<stan::math::var_value<double>, -1, 1, 0> &, double, double, stan::math::var_value<double>>::build' requested here
return ops_partials.build(logp);
^
stan_files/bernoulli.hpp:4388:13: note: in instantiation of function template specialization 'stan::math::bernoulli_logit_glm_lpmf<false, std::__1::vector<int>, Eigen::Matrix<double, -1, -1, 0>, stan::math::var_value<double>, Eigen::Matrix<stan::math::var_value<double>, -1, 1, 0>, nullptr>' requested here
bernoulli_logit_glm_lpmf<false>(y, XS,
^
stan_files/bernoulli.hpp:6121:14: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob_impl<true, true, std::__1::vector<stan::math::var_value<double>>, std::__1::vector<int>, nullptr, nullptr>' requested here
return log_prob_impl<propto__, jacobian__>(params_r, params_i, pstream);
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/log_prob_grad.hpp:40:36: note: in instantiation of function template specialization 'model_bernoulli_namespace::model_bernoulli::log_prob<true, true, stan::math::var_value<double>>' requested here
var adLogProb = model.template log_prob<propto, jacobian_adjust_transform>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/util/initialize.hpp:166:31: note: in instantiation of function template specialization 'stan::model::log_prob_grad<true, true, model_bernoulli_namespace::model_bernoulli>' requested here
log_prob = stan::model::log_prob_grad<true, Jacobian>(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/services/diagnose/diagnose.hpp:49:43: note: in instantiation of function template specialization 'stan::services::util::initialize<true, model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
std::vector<double> cont_vector = util::initialize(
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:481:45: note: in instantiation of function template specialization 'stan::services::diagnose::diagnose<model_bernoulli_namespace::model_bernoulli>' requested here
return_code = stan::services::diagnose::diagnose(model,
^
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:1215:11: note: in instantiation of function template specialization 'rstan::(anonymous namespace)::command<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>' requested here
ret = command(args, model_, holder, names_oi_tidx_,
^
stan_files/bernoulli.cc:13:87: note: in instantiation of member function 'rstan::stan_fit<model_bernoulli_namespace::model_bernoulli, boost::random::additive_combine_engine<boost::random::linear_congruential_engine<unsigned int, 40014, 0, 2147483563>, boost::random::linear_congruential_engine<unsigned int, 40692, 0, 2147483399>>>::call_sampler' requested here
.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
^
In file included from stan_files/bernoulli.cc:3:
In file included from stan_files/bernoulli.hpp:18:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/rstaninc.hpp:4:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstan/include/rstan/stan_fit.hpp:48:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/src/stan/model/model_base.hpp:5:
In file included from /Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core.hpp:52:
/Library/Frameworks/R.framework/Versions/4.2/Resources/library/StanHeaders/include/stan/math/rev/core/precomputed_gradients.hpp:86:60: warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
container_gradients_(index_apply<N_containers>([&, this](auto... Is) {
^
38 warnings and 1 error generated.
make: *** [stan_files/bernoulli.o] Error 1
rm stan_files/bernoulli.cc
ERROR: compilation failed for package ‘rstanarm’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2/Resources/library/rstanarm’
Warning messages:
1: R graphics engine version 15 is not supported by this version of RStudio. The Plots tab will be disabled until a newer version of RStudio is installed.
2: In i.p(...) :
installation of package ‘/var/folders/59/4rn659ld3tzgzyzbnglmvnqw0000gp/T//Rtmph6l7tx/file55655c28537c/rstanarm_2.21.2.tar.gz’ had non-zero exit status