| make_sf | R Documentation |
Creates a survival function from a hazard rate which was calculated on a grid.
make_sf(step_size_s_grid, haz)
step_size_s_grid |
Numeric value indicating the distance between two grid continuous grid points. |
haz |
Vector of hazard values. Hazard rate must have been calculated on a time grid. |
The function make_sf calculates the survival function
S(t) = \exp (-\int_0^t h(t) dt),
where h is the hazard rate. Here, a discritisation via an equidistant grid \{ t_i \} on [0,t] is used to calculate the integral and it is assumed that h has been calculated for exactly these time points t_i .
A vector of values S(t_i).
make_sf(0.1, rep(0.1,10))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.