Learn R Programming

RoBMA (version 1.2.0)

summary.RoBMA: Summarize fitted RoBMA object

Description

summary.RoBMA creates a numerical summary of the RoBMA object.

Usage

# S3 method for RoBMA
summary(
  object,
  type = if (diagnostics) "models" else "ensemble",
  conditional = FALSE,
  diagnostics = FALSE,
  include_theta = FALSE,
  probs = c(0.025, 0.975),
  logBF = FALSE,
  BF01 = FALSE,
  digits_estimates = 3,
  digits_BF = 3,
  ...
)

Arguments

object

a fitted RoBMA object.

type

whether to show the overall RoBMA results ("ensemble"), an overview of the individual models ("models"), or detailed summary for the individual models ("individual").

conditional

show the conditional estimates (assuming that the alternative is true). Defaults to FALSE. Only available for type == "conditional".

diagnostics

show the maximum R-hat and minimum ESS for the main parameters in each of the models. Only available for type = "ensemble".

include_theta

whether the estimated random effects should be included either in the summaries.

probs

quantiles of the posterior samples to be displayed. Defaults to c(.025, .50, .975)

logBF

show log of the BFs. Defaults to FALSE.

BF01

show BF in support of the null hypotheses. Defaults to FALSE.

digits_estimates

a number of decimals for rounding the estimates. Defaults to 3.

digits_BF

a number of decimals for rounding the BFs. Defaults to 3.

...

additional arguments

Value

summary of a RoBMA object

See Also

RoBMA() diagnostics()

Examples

Run this code
# NOT RUN {
# using the example data from Anderson et al. 2010 and fitting the default model
# (note that the model can take a while to fit)
fit <- RoBMA(r = Anderson2010$r, n = Anderson2010$n, study_names = Anderson2010$labels)

# summary can provide many details about the model
summary(fit)

# note that the summary function contains additional arguments
# that allow to obtain a specific output, i.e, the conditional estimates
# (assuming that the non-null models are true) can be obtained
summary(fit, conditional = TRUE)

# overview of the models and their prior and posterior probability, marginal likelihood,
# and inclusion Bayes factor:
summary(fit, type = "models")

# and the model diagnostics overview, containing maximum R-hat and minimum ESS across parameters
# but see '?diagnostics' for diagnostics plots for individual model parameters
summary(fit, type = "models", diagnostics = TRUE)

# summary of individual models and their parameters can be further obtained by
summary(fit, type = "individual")

# }

Run the code above in your browser using DataLab