Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow dispersion parameter to be observation-specific #481

Open
fweber144 opened this issue Nov 23, 2023 · 1 comment
Open

Allow dispersion parameter to be observation-specific #481

fweber144 opened this issue Nov 23, 2023 · 1 comment
Labels
enhancement Enhancements of existing features, but also new feature requests.

Comments

@fweber144
Copy link
Collaborator

This is a feature request to allow the dispersion parameter to be observation-specific, as, for example, in models like the following:

library(brms)
set.seed(4734)
data_het <- data.frame(
  y = c(rnorm(50), rnorm(50, 1, 2)),
  x = factor(rep(c("a", "b"), each = 50)),
  se_y = rgamma(100, shape = 1)
)
fit6 <- brm(y | se(se_y, sigma = TRUE) ~ x, data = data_het)
stancode(fit6)
str(standata(fit6))

This came up in https://discourse.mc-stan.org/t/accounting-for-measurement-error-during-variable-selection-with-projpred-possibly-with-rstanarm-or-brms/11789.

@fweber144 fweber144 added the enhancement Enhancements of existing features, but also new feature requests. label Nov 23, 2023
@fweber144
Copy link
Collaborator Author

I guess we will need special submodel fitters for this (or at least adapt the currently available ones), so that the observation-specific dispersion parameter values are taken into account when performing the projection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancements of existing features, but also new feature requests.
Projects
None yet
Development

No branches or pull requests

1 participant