plot_cure {CureDepCens}R Documentation

Plot the survival function

Description

This graph helps to visualize the survival function.

Usage

plot_cure(object, scenario = c("t", "c", "both"))

Arguments

object

an object of the class "dcensoring".

scenario

which defines the scenario in the graph (t: failure times, c: dependent censoring times, or both).

Details

In order to smooth the line presented in the graph, we used the 'lowess' function. So, it can result in a non-monotonous survival function.

Value

a survival function graph of the fitted model.

Examples


library(CureDepCens)

delta_t = ifelse(Dogs_MimicData$cens==1,1,0)
delta_c = ifelse(Dogs_MimicData$cens==2,1,0)

fit <- cure_dep_censoring(formula = time ~ x1_cure + x2_cure | x_c1 + x_c2,
                          data = Dogs_MimicData,
                          delta_t = delta_t,
                          delta_c = delta_c,
                          ident = Dogs_MimicData$ident,
                          dist = "mep")

plot_cure(fit, scenario = "t")



[Package CureDepCens version 0.1.0 Index]