boot.joint {gmvjoint}R Documentation

Bootstrapping a joint object

Description

Use an existing model fit by joint along with the data object originally used and obtain a mean estimate, standard errors and 95% confidence interval using the bootstrap. The original data is resampled by subject, not by observation.

Usage

boot.joint(
  fit,
  data,
  boot.size = NULL,
  nboot = 100L,
  replace = TRUE,
  progress = TRUE,
  use.MLEs = TRUE,
  control = list()
)

Arguments

fit

a joint model fit by the joint function.

data

the original data used to fit the above joint model.

boot.size

integer, specifies the number of subjects to resample in the bootstrapping approach. The default value is boot.size = NULL which defaults to the number of unique subjects in the joint object.

nboot

integer, specifies the number of bootstrap samples, default value is nboot = 100L.

replace

logical, should sampling be done with replacement? Defaults to replace = TRUE.

progress

logical, should a text progress bar showing overall progress be shown and updated after each successful bootstrapped model fit? Defaults to progress=TRUE.

use.MLEs

logical, should the MLEs of the fit be used as initial conditions in each of the bootstrapped calls to joint? Defaults to use.MLEs=TRUE which should help reduce the computational burden in fitting these bootstrap replicate joint objects.

control

a list of control arguments, with same possible arguments as shown in joint. Note that by default the same control arguments used in the joint fit parameter are carried forwards, besides the items return.dmats, post.process, and verbose which are all set to FALSE in boot.joint in order to reduce memory overheads and computation time. Instead, the user could lessen computational burden of this intensive bootstrapping by changing convergence criteria items e.g. conv, tol.rel, tol.abs, tol.thr in order to speed-up convergence of the nboot individual bootstrapped model fits.

Value

A list of class boot.joint which contains the MLEs from supplied joint object, as well as the bootstrapped summaries and some model/computation information.

Author(s)

James Murray (j.murray7@ncl.ac.uk).

See Also

joint vcov.joint

Examples


# Bivariate fit on PBC data -----------------------------------------
data(PBC)

# Subset data and remove NAs
PBC <- subset(PBC, select = c('id', 'survtime', 'status', 'drug', 'time',
                              'albumin', 'platelets'))
PBC <- na.omit(PBC) 

# Specify bivariate fit
long.formulas <- list(
  albumin ~ time*drug + (1 + time|id),
  platelets ~ time * drug + (1 + time|id)
)
surv.formula <- Surv(survtime, status) ~ drug

fit <- joint(long.formulas, surv.formula, PBC, family = list('gaussian', 'poisson'))
# Set 50 bootstraps, with lower absolute tolerance and convergence of 'either'.
BOOT <- boot.joint(fit, PBC, nboot = 50L, control = list(tol.abs = 5e-3, conv = 'either'),
                   use.MLEs = TRUE)
BOOT # Print to console via S3 method


[Package gmvjoint version 0.4.0 Index]