# plot.simfrail: Plot method for 'simfrail' objects In frailtySurv: General Semiparametric Shared Frailty Model

## Description

Plot the estimated parameter residuals or the mean estimated cumulative baseline hazard.

## Usage

 ```1 2``` ```## S3 method for class 'simfrail' plot(x, type = c("residuals", "cumhaz"), ...) ```

## Arguments

 `x` a `fitfrail` object `type` string, the type of plot. Can be either "residuals" or "cumhaz". If `type="residuals"`, a boxplot of the estimated parameter residuals is created. If `type="cumhaz"`, the mean estimated and true cumulative baseline hazard are plotted. `...` extra arguments include: `CI` for `type="cumhaz"`, the confidence interval for the empirical cumulative baseline hazard. `n.Lambda` for `type="residuals"`, the number of time points to show the cumulative baseline hazard residuals for.

The plot object.

## Author(s)

John. V Monaco, Malka Gorfine, Li Hsu

`simfrail`
 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19``` ```## Not run: set.seed(2015) sim <- simfrail(1000, genfrail.args=alist(beta=c(log(2),log(3)), frailty="gamma", censor.rate=0.30, N=300, K=2, theta=2, covar.distr="uniform", covar.param=c(0, 1), Lambda_0=function(t, tau=4.6, C=0.01) (C*t)^tau), fitfrail.args=alist(formula=Surv(time, status) ~ Z1 + Z2 + cluster(family), frailty="gamma"), Lambda.times=1:120) # Make a boxplot of residuals plot(sim, type="residuals") # Plot the mean estimated cumulative baseline hazard and empirical 0.95 CI plot(sim, type="cumhaz") ## End(Not run) ```