marginal_gof_plots_scr {Surrogate}R Documentation

Marginal survival function goodness of fit

Description

The marginal_gof_plots_scr() function plots the estimated marginal survival functions for the fitted model. This results in four plots of survival functions, one for each of S_0, S_1, T_0, T_1.

Usage

marginal_gof_plots_scr(fitted_model, grid)

Arguments

fitted_model

Returned value from fit_model_SurvSurv(). This object essentially contains the estimated identifiable part of the joint distribution for the potential outcomes.

grid

grid of time-points for which to compute the estimated survival functions.

Examples

data("Ovarian")
#For simplicity, data is not recoded to semi-competing risks format, but is
#left in the composite event format.
data = data.frame(
  Ovarian$Pfs,
  Ovarian$Surv,
  Ovarian$Treat,
  Ovarian$PfsInd,
  Ovarian$SurvInd
)
ovarian_fitted =
  fit_model_SurvSurv(data = data,
                     copula_family = "clayton",
                     n_knots = 1)
grid = seq(from = 0, to = 2, length.out = 50)
Surrogate:::marginal_gof_plots_scr(ovarian_fitted, grid)


[Package Surrogate version 3.2.5 Index]