km.sim.survtimes {CPsurv}R Documentation

Simulates Survival Times using Kaplan-Meier

Description

Simulates Survival Times using Kaplan-Meier

Usage

km.sim.survtimes(nobs, time, event, weibexp, changeP = NULL)

Arguments

nobs

Number of observations.

time

Numeric vector with survival times.

event

Numeric vector indicating censoring status; 0 = alive (censored), 1 = dead (uncensored). If missing, all observations are assumed to be uncensored.

weibexp

Logical; if TRUE, survival times above change point have constant hazard; if FALSE all survival times are generated by using the estimated survival curve (relevant for generation of censoring times).

changeP

Change point


[Package CPsurv version 1.0.0 Index]