Skip to content

Use LOO CV with validated search in the vignettes and add alt text to the figures - #656

Merged
avehtari merged 46 commits into
masterfrom
vignette-main-loo
Nov 19, 2026
Merged

avehtari merged 46 commits into
masterfrom
vignette-main-loo

Conversation

@avehtari

Copy link
Copy Markdown
Member

Closes #526. Plus other updates.

Merge #655 first.

Vignettes

projpred.Rmd:

latent.Rmd:

  • The examples use forward search and LOO CV with validated search. The Weibull and log-normal examples now use full LOO CV (before: nloo = 10).
  • The Poisson and negative binomial examples each use one simulated data set (no separate test data) and cv_varsel(). The Poisson example compares the latent and the traditional projection with forward search.
  • The text no longer presents L1 search as a reason for the latent projection.

All 13 figures have alt text (fig.alt). Each alt text names the plot type and the result that the vignette text reads from the figure. Five alt texts repeat submodel sizes from the vignette text; when these sizes change, update both places.

Code

The latent-projection examples gave output that the vignette text had to explain. This PR changes that output:

  • A latent reference model no longer gives a message about an NA dispersion.
  • Families whose inverse link gives the mean (for example, negative binomial and Weibull) no longer give the latent_ilink message.
  • Without a dispersion, as.matrix() and as_draws_matrix() of a latent projection have no sigma column.

New tests are in test_extend_family.R and test_latent.R.

Checks

On Roihu (R 4.6.1), projpred.Rmd renders in 16 s and latent.Rmd in 346 s. The full test suite with NOT_CRAN=true gives 0 failures and 0 errors, and R CMD check gives 0 errors, 0 warnings and 0 notes.

This PR was assisted by Claude.

@avehtari avehtari added the documentation Documentation issues. label Nov 18, 2026
Comment thread vignettes/latent.Rmd Resolved
Comment thread vignettes/projpred.Rmd Resolved
@avehtari
avehtari merged commit 2a03159 into master Nov 19, 2026
6 checks passed
@avehtari
avehtari deleted the vignette-main-loo branch November 19, 2026 11:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Documentation issues.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Alt text for vignettes

2 participants