I have run a Gaussian model on data with an upper-censored response. ESS seems good and there are no warnings with the fit, but when I run loo
, bayes_R2
, or loo_R2
, I get the following error
Error : vector memory exhausted (limit reached?)
Error: Something went wrong (see the error message above). Perhaps you transformed numeric variables to factors or vice versa within the model formula? If yes, please convert your variables beforehand. Or did you set a predictor variable to NA?
And this is despite setting nsamples
to a fairly low number. The code I am running is
mdl_tapped_pulse_tap_vel_red <-
brm(
bf(
tap_vel | cens(censoring) ~
cue *
(tap_l_1 +
perf_num_sc + repetition_sc +
N_sc + mean_IOI_sc +
CQ_sc + balance_sc +
proj_cent_sc + height_sc +
duple_triple +
Markov2_sc + edge_sc),
decomp = "QR"),
data = WF_rhythm_data_tapped,
family = gaussian(),
prior = c(set_prior("student_t(3, 0, 1)", class = "Intercept"),
set_prior("student_t(3, 0, 1)", class = "b")),
save_pars = save_pars(all = TRUE),
file = "mdl_tapped_pulse_tap_vel_red")
mdl_tapped_pulse_tap_vel_red <-
add_criterion(
mdl_tapped_pulse_tap_vel_red,
c("loo", "bayes_R2", "loo_R2"),
nsamples = 500
)
loo(mdl_tapped_pulse_tap_vel_red)
bayes_R2(mdl_tapped_pulse_tap_vel_red )
loo_R2(mdl_tapped_pulse_tap_vel_red)
I am running brms 2.14.0.
I am not sure how to proceed or if this is a bug. Thanks in advance for any suggestions.