Effective Sample Size (ESS)Source:
This function returns the effective sample size (ESS).
effective_sample(model, ...) # S3 method for brmsfit effective_sample( model, effects = c("fixed", "random", "all"), component = c("conditional", "zi", "zero_inflated", "all"), parameters = NULL, ... ) # S3 method for stanreg effective_sample( model, effects = c("fixed", "random", "all"), component = c("location", "all", "conditional", "smooth_terms", "sigma", "distributional", "auxiliary"), parameters = NULL, ... )
Currently not used.
Should results for fixed effects, random effects or both be returned? Only applies to mixed models. May be abbreviated.
Should results for all parameters, parameters for the conditional model or the zero-inflated part of the model be returned? May be abbreviated. Only applies to brms-models.
Regular expression pattern that describes the parameters that should be returned. Meta-parameters (like
prior_) are filtered by default, so only parameters that typically appear in the
summary()are returned. Use
parametersto select specific parameters for the output.
Effective Sample (ESS) should be as large as possible, altough for most applications, an effective sample size greater than 1,000 is sufficient for stable estimates (Bürkner, 2017). The ESS corresponds to the number of independent samples with the same estimation power as the N autocorrelated samples. It is is a measure of “how much independent information there is in autocorrelated chains” (Kruschke 2015, p182-3).
Kruschke, J. (2014). Doing Bayesian data analysis: A tutorial with R, JAGS, and Stan. Academic Press.
Bürkner, P. C. (2017). brms: An R package for Bayesian multilevel models using Stan. Journal of Statistical Software, 80(1), 1-28