Skip to content

Upcoming breaking changes in loo_compare() output#116

Open
florence-bockting wants to merge 4 commits intojsocolar:mainfrom
florence-bockting:fix-loo_compare
Open

Upcoming breaking changes in loo_compare() output#116
florence-bockting wants to merge 4 commits intojsocolar:mainfrom
florence-bockting:fix-loo_compare

Conversation

@florence-bockting
Copy link
Copy Markdown

Description

In the loo package, we are making changes to the output structure returned by loo_compare() in PR #300. The main changes are a transition from a matrix to a data frame and the addition of several new columns. Here is an example of the updated output structure:

> loo_compare(w1, w2)
  model elpd_diff se_diff p_worse diag_diff diag_elpd
 model1       0.0     0.0      NA                    
 model2      -4.1     0.1    1.00   N < 100     
     
Diagnostic flags present.
See ?`loo-glossary` (sections `diag_diff` and `diag_elpd`)
or https://mc-stan.org/loo/reference/loo-glossary.html.

More context on the motivation behind these changes can be found in the updated case study "Uncertainty in Bayesian LOO-CV Model Comparison".

A reverse dependency check revealed that these changes will affect your package. To help smooth the transition, I have already reviewed your code and suggest within this PR changes that should keep your package compatible with both the current and the upcoming loo_compare() output structure.

I may have missed some additional spots in your code that need updating, so please feel free to point those out and I am happy to help. Thank you and please do not hesitate to reach out if you have any questions or concerns.

TODO

  • I noticed one aspect related to flocker_tutorial.Rmd where I am uncertain how you want to handle this. In the section "Post-processing > Model comparison" you currently provide the expected output in form of a comment. This expected output will change for the new loo_compare() function.

@florence-bockting florence-bockting marked this pull request as ready for review April 22, 2026 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant