plot.IDEMIMP {idem}R Documentation

Plot imputation results

Description

Generate different types of plots for class IDEMIMP objects generated by imImpAll

Usage

## S3 method for class 'IDEMIMP'
plot(x, opt = c("imputed", "composite"), fname = NULL, ...)

Arguments

x

A class IDEMIMP object returned from imImpAll

opt

Types of the plot

  • imputed: Plot density of imputed values and the density of the observed outcomes

  • composite: Generate cumulative plot of the composite survival and functional outcome

fname

File name of the result pdf file. If fname is null, result pdf file will not be generated

...

Options for generating the plots.

type = imputed
  • deltas: Imputation sensitivity parameter for which to generate the results

  • endp: If TRUE, plot the densities of the imputed functional outcomes. Otherwise, plot the densities of the imputed outcomes

  • adjdensity estimation option

  • colsplot option for colors

  • ltysplot options for line types

  • xlimplot options

  • ylimplot options

  • mfrowplot options

type = composite
  • at.surv: Sets the range of the survival times to plot in the cumulative distribution function. By default the range is the range of survival values up to the duration of the study

  • at.z: Sets the range of the functional outcome to plot in the cumulative distribution function. By defualt this is the range of the functional outcomes plus the buffer amount to improve visibility in the transition from survival to functional outcome

  • p.death: Proportion of the plot width devoted to Survival. By default the cumulative distribution will devote horizontal space to the survival portion that is proportional to the number of subjects who die prior to duration

  • buffer: Small horizontal gap used to better visually distinguish the transition from survival to functional outcome

  • delta: Imputation sensitivity parameter for which to generate the results

  • seg.lab: Labels for the two components of the composite outcome

  • main: plot options

See Also

imImpAll

Examples

## Not run: 
im.abc <- imData(abc, trt="TRT", surv="SURV", outcome=c("Y1","Y2"),
                 y0=NULL, endfml="Y2",
                 trt.label = c("UC+SBT", "SAT+SBT"),
                 cov=c("AGE"), duration=365, bounds=c(0,100));
rst.fit  <- imFitModel(im.abc);
rst.imp <- imImpAll(rst.fit, deltas=c(-0.25,0,0.25),
                    normal=TRUE, chains = 2, iter = 2000, warmup = 1000);
plot(rst.imp, opt = "imputed"),
plot(rst.imp, opt = "composite")
## End(Not run)

[Package idem version 5.2 Index]