Skip to content

Allow dispersion parameter to be observation-specific #481

@fweber144

Description

@fweber144

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementEnhancements of existing features, but also new feature requests.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions