I’ve been using Rstan and loo to develop my utility model with hierarchical structure (38 subjects).
However, due to the novelty of current model, I can’t decide the optimal ranges for my six parameters. So I tried different ranges, for example, for parameter alpha, I tried [-2,2] (model A) and [-20,20] (model B).
# model A
transformed parameters {
vector<lower=-2, upper=2>[N] alpha;
}
# model B
transformed parameters {
vector<lower=-20, upper=20>[N] alpha;
}
the corresponding results differed a lot. In model B, the distribution of alpha was more normal and seemed better.
However, when it comes to the diagnostics, the model B has a much huger LOOIC than model A.
#model A
Computed from 6000 by 38 log-likelihood matrix
Estimate SE
elpd_loo -1795.3 44.7
p_loo 106.2 19.7
looic 3590.6 89.5
------
Monte Carlo SE of elpd_loo is NA.
Pareto k diagnostic values:
Count Pct. Min. n_eff
(-Inf, 0.5] (good) 18 47.4% 328
(0.5, 0.7] (ok) 11 28.9% 68
(0.7, 1] (bad) 4 10.5% 15
(1, Inf) (very bad) 5 13.2% 1
See help('pareto-k-diagnostic') for details.
#model B
Computed from 6000 by 38 log-likelihood matrix
Estimate SE
elpd_loo -6813.3 1246.0
p_loo 5626.6 1161.0
looic 13626.6 2491.9
------
Monte Carlo SE of elpd_loo is NA.
Pareto k diagnostic values:
Count Pct. Min. n_eff
(-Inf, 0.5] (good) 0 0.0% <NA>
(0.5, 0.7] (ok) 0 0.0% <NA>
(0.7, 1] (bad) 2 5.3% 16
(1, Inf) (very bad) 36 94.7% 0
See help('pareto-k-diagnostic') for details.
the following the short version of scripts:
fit = rstan::stan(model)
looic = loo(fit)
looic
Moreover, I also calculated BIC which indicated an inversed pattern, that model B had a lower BIC.
Hence, I was completely confused by the these results and wanted to know (1) whether the data is not big enough or there are some problems in model specification to result in such a large LOOIC ( the smallest looic is still big); (2) why did the change of parameter range elicited such huge difference?
Thanks!!