Model_weights function with reloo

When I re-fit a model that has a problematic observation as indicated by the Pareto k >0.7, using the following code,

model_reloo <- LOO(model, reloo= TRUE)

It returns a list, not a brmsfit object.

If I’m comparing this reloo model to others that don’t need to be refit (Pareto k good), and want to use the brms function, “loo_compare()”, it won’t allow me to because it requires brmsfit objects.

How do I include the model_reloo in the model weight comparison?

Thanks and sorry I don’t have reproducible code. I’m hoping this is straightforward, easy fix that I have missed in the documentation.

  • Operating System: Windows
  • brms Version: 2.8.0

Denise

You can extract loo objects from brmsfit objects via model$loo or loo(model). You may also store updated loo objects manually for instance via

model$loo <- loo(model, reloo= TRUE)

(LOO() is an alias of loo())

1 Like

Awesome thank you~!