get_data: get_data

Description Usage Arguments Value Examples

View source: R/deprecated-get_data.R

Description

Extract data slots from an object of class simsum, summary.simsum, multisimsum, or summary.multisimsum.

Usage

1

Arguments

x

An object of class simsum.

stats

Summary statistics to include; can be a scalar value or a vector. Possible choices are:

  • nsim, the number of replications with non-missing point estimates and standard error.

  • thetamean, average point estimate.

  • thetamedian, median point estimate.

  • se2mean, average standard error.

  • se2median, median standard error.

  • bias, bias in point estimate.

  • empse, empirical standard error.

  • mse, mean squared error.

  • relprec, percentage gain in precision relative to the reference method.

  • modelse, model-based standard error.

  • relerror, relative percentage error in standard error.

  • cover, coverage of a nominal level\

  • becover, bias-eliminated coverage of a nominal level\

  • power, power of a (1 - level)\ Defaults to NULL, in which case all summary statistics are returned.

...

Ignored.

Value

A data.frame containing summary statistics from a simulation study.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
data(MIsim)
x <- simsum(
  data = MIsim, estvarname = "b", true = 0.5, se = "se",
  methodvar = "method"
)
get_data(x)

# Extracting only bias and coverage:
get_data(x, stats = c("bias", "cover"))

xs <- summary(x)
get_data(xs)

rsimsum documentation built on May 21, 2021, 5:06 p.m.