View source: R/summary_fitsae.R
summary.fitsae | R Documentation |
fitsae
ObjectsSummarizing the small area model fitting through the distributions of estimated parameters and derived diagnostics using posterior draws.
## S3 method for class 'fitsae'
summary(
object,
probs = c(0.025, 0.25, 0.5, 0.75, 0.975),
compute_loo = TRUE,
...
)
object |
An instance of class |
probs |
A numeric vector of |
compute_loo |
Logical, indicating whether to compute |
... |
Currently unused. |
If printed, the produced summary displays:
Posterior summaries about the fixed effect coefficients and the scale parameters related to unstructured and possible structured random effects.
Model diagnostics summaries of (a) model residuals; (b) standard deviation reductions; (c) Bayesian P-values obtained with the MCMC samples.
Shrinking Bound Rate.
loo
information criteria and related diagnostics from the loo
package.
A list of class summary_fitsae
containing diagnostics objects:
raneff
A list of data.frame
objects storing the random effects posterior summaries divided for each type: $unstructured
, $temporal
, and $spatial
.
fixed_coeff
Posterior summaries of fixed coefficients.
var_comp
Posterior summaries of model variance parameters.
model_estimates
Posterior summaries of the parameter of interest \theta_d
for each in-sample domain d
.
model_estimates_oos
Posterior summaries of the parameter of interest \theta_d
for each out-of-sample domain d
.
is_oos
Logical vector defining whether each domain is out-of-sample or not.
direct_est
Vector of input direct estimates.
post_means
Model-based estimates, i.e. posterior means of the parameter of interest \theta_d
for each domain d
.
sd_reduction
Standard deviation reduction, see details section.
sd_dir
Standard deviation of direct estimates, given as input if type_disp="var"
.
loo
The object of class loo
, for details see loo
package documentation.
shrink_rate
Shrinking Bound Rate, see details section.
residuals
Residuals related to model-based estimates.
bayes_pvalues
Bayesian p-values obtained via MCMC samples, see details section.
y_rep
An array with values generated from the posterior predictive distribution, enabling the implementation of posterior predictive checks.
diag_summ
Summaries of residuals, standard deviation reduction and Bayesian p-values across the whole domain set.
data_obj
A list containing input objects including in-sample and out-of-sample relevant quantities.
model_settings
A list summarizing all the assumptions of the input model: sampling likelihood, presence of intercept, dispersion parametrization, random effects priors and possible structures.
call
Image of the function call that produced the input fitsae
object.
janicki2020propertiestipsae
\insertRefvehtari2017practicaltipsae
\insertRefJSStipsae
fit_sae
to estimate the model and the generic methods plot.summary_fitsae
and density.summary_fitsae
, and functions map
, benchmark
and extract
.
library(tipsae)
# loading toy dataset
data("emilia_cs")
# fitting a model
fit_beta <- fit_sae(formula_fixed = hcr ~ x, data = emilia_cs, domains = "id",
type_disp = "var", disp_direct = "vars", domain_size = "n",
# MCMC setting to obtain a fast example. Remove next line for reliable results.
chains = 1, iter = 150, seed = 0)
# check model diagnostics via summary() method
summ_beta <- summary(fit_beta)
summ_beta
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.