That log_lik matrix has +Inf values, and loo package silently passes them. +Inf values likely arise from the normalization term of the truncated likelihood (that is the integral of normal from 0 to 1) underflowing to 0, and then the untruncated likelihood values is divided by 0. It seems like truncated normal is not a good model, covariates have large values, or priors are to vague, so that the normal mean is smaller than 0 or larger than 1 and normal sd is so small, that the probability in the range from 0 to 1 is super small. Firstly, this is a problem with your model and secondly truncated likelihood computation in brms could be possibly made numerically better to not underflow or to provide warning in a case of underflow. Tagging @Florence_Bockting, who has recently worked on brms code related to this.
avehtari
12
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Choosing a sampling distribution for left skewed data | 15 | 2252 | March 20, 2024 | |
| Conditional truncation including -Inf | 11 | 1204 | March 6, 2023 | |
| Comparing complex multivariate models with loo_compare | 13 | 1939 | September 30, 2020 | |
| Loo::add_criterion() aborts R session for cmdstanr model | 12 | 1431 | July 3, 2021 | |
| Error with add_criterion(..., "loo") | 12 | 2276 | March 15, 2024 |