full_model = bf(choice ~ inv_logit((rewmag/(1 + exp(logk)*delay) - smag)/noise),
noise ~ (1|subjid), logk ~ (treat|subjid), nl = TRUE)
full_fit = brm(full_model,
data = all_trials, family = bernoulli(link='identity'),
prior = c(prior(normal(-3,4), nlpar = 'logk'), prior(normal(1,10),lb = 0, nlpar = 'noise')),
inits = "0",
chains = 10, iter = 10000, warmup=2000, cores = 10)
"Simpler" Model
simple_model = bf(choice ~ inv_logit((rewmag/(1 + exp(logk)*delay) - smag)/noise),
noise ~ (1|subjid), logk ~ (1|treat) + (1|subjid), nl = TRUE)
simple_fit = brm(simple_model,
data = all_trials, family = bernoulli(link='identity'),
prior = c(prior(normal(-3,4), nlpar = 'logk'), prior(normal(1,10),lb = 0, nlpar = 'noise')),
inits = "0",
chains = 20, iter = 25000, warmup=10000, cores = 22)
Both models ran with OK diagnostics (reasonable number of effective samples, Rhat ~ 1).However, when I run `loo` to do model comparison I get this:
> loo::loo(extract_log_lik(simple_fit$fit, parameter_name = 'lp__')) . # is the lp__ the right thing to use here?
Computed from 200000 by 1 log-likelihood matrix
Estimate SE
elpd_loo -13748.1 NA
p_loo 91.9 NA
looic 27496.3 NA
Pareto k diagnostic values:
Count Pct
(-Inf, 0.5] (good) 0 0.0%
(0.5, 0.7] (ok) 0 0.0%
(0.7, 1] (bad) 0 0.0%
(1, Inf) (very bad) 1 100.0%
See help('pareto-k-diagnostic') for details.
Warning message:
Some Pareto k diagnostic values are too high. See help('pareto-k-diagnostic') for details.Why is the SE==NA?What does it mean that the Pareto k diagnostic values are too bad. How can I compare the models?I tried to read Vehtari, et al (2016) but it is over my head. (Apologies if this would be better asked in a different group).
--
You received this message because you are subscribed to the Google Groups "brms-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to brms-users+unsubscribe@googlegroups.com.
To post to this group, send email to brms-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/brms-users/bf72d029-fc35-42b5-81f4-76322964e30c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
> brms::LOO(full_fit, simple_fit) Switching to pointwise evaluation to reduce RAM requirements. This will likely increase computation time. Error in draws[["C"]][[cov]] <- as_draws_matrix(C[, cov], dim = c(nsamples, : long vectors not supported yet: ../../src/include/Rinlinedfuns.h:138 | |
|
To unsubscribe from this group and stop receiving emails from it, send an email to brms-users+...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to brms-users+unsubscribe@googlegroups.com.
To post to this group, send email to brms-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/brms-users/64f164e7-4469-4700-9489-5c230eb9cbbd%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "brms-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to brms-users+unsubscribe@googlegroups.com.
To post to this group, send email to brms-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/brms-users/36006f8e-1cdb-4d3f-9e91-cf2ffbed7581%40googlegroups.com.