get_hazard_offset_weights {semicmprskcoxmsm} | R Documentation |
Compute the (Cumulative) Baseline Hazard from Cox Model with Offsets
Description
Compute the Breslow type baseline hazard and cumulative baseline hazard at each event time from a weighted Cox model with offsets.
Usage
get_hazard_offset_weights(fit,data,time1= NULL,time2,w)
Arguments
fit |
The results of a weighted |
data |
The original data for fitting the weighted Cox model. |
time1 |
The default is |
time2 |
For right censored data, this is the event time or censoring time. For left truncation data, the argument is the time to terminal event or the censoring time. |
w |
IP weights. |
Details
See also get_hazard
, handles the offset term in coxph
for predicting the baseline hazard.
Value
A list contains two dataframes.
Lambda |
See also |
lambda |
Returns a dataframe for baseline hazard. |
cum_base_haz |
Returns a dataframe for cumulative baseline hazard. |
See Also
get_hazard
, basehaz