rcuref {rcens} | R Documentation |
Title Generate Sample with Cure Fraction
Description
Generator Sample with Cure Fraction, given a generator of samples of the distribution X (rdistrX) with parameters appended by the list param_X. Also the proportion of cure desired p.
Usage
rcuref(rdistrX, param_X, n = 10000, p = 0.5)
Arguments
rdistrX |
sample generator of distribution X. |
param_X |
list with parameters of rdistrX function. |
n |
number of sample to create. |
p |
cure fraction |
Value
A list with sample data information:
data_cf | vector of cure fraction sample. |
cure_list | vector of 1 and 0 indicating whether the i-th sample is cured. |
1:= cure , 0:= no cure | |
cure_fraction | cure fraction used to create de sample. |
Author(s)
Daniel Saavedra Morales
Examples
#Example Exponential Cure Fraction p = 0.5
Data = rcuref(rdistrX = rexp, param_X = list("rate" = 1),
n = 1000, p = 0.5)
[Package rcens version 0.1.1 Index]