Hi all,
I have constructed a flexible parametric survival model using stpm2 on Stata 13.1 on the scale (hazard), with a df of 3. I've obtained the coefficients of my covariate (pi_linear) , _rcs [1 to 3] and the constant term as shown below.

I wish to now predict survival probabilities at various time points using this model on an external platform. Therefore I wish to represent this parametric survival model mathematically for estimating log cumulative hazard at various time points. I am having trouble writing out the equation for the spline basis functions. I have read chapter 5 of the Textbook by Royston and Lambert on Flexible Parametric Survival Analysis Using Stata: Beyond the Cox Model, which provides a general equation (in page 110) using ln t, z1 and z2 but I am confused about how to obtain z1 and z2 for computing my log cumulative hazard at a specific time point. From page 110 :
generate lnH = _b[_cons] + _rcs1 * _b[_rcs1] + _rcs2 * _b[_rcs2] + _rcs3 * _b[rcs3]
Specifically I would like to ask where can I obtain the estimates for _b[rcs1], _b[_rcs2] and _b[_rcs3] for the above model in order to write out the log cumulative hazard function for the model above.
Any leads are most appreciated!
Thank you very much.
Manee
I have constructed a flexible parametric survival model using stpm2 on Stata 13.1 on the scale (hazard), with a df of 3. I've obtained the coefficients of my covariate (pi_linear) , _rcs [1 to 3] and the constant term as shown below.
I wish to now predict survival probabilities at various time points using this model on an external platform. Therefore I wish to represent this parametric survival model mathematically for estimating log cumulative hazard at various time points. I am having trouble writing out the equation for the spline basis functions. I have read chapter 5 of the Textbook by Royston and Lambert on Flexible Parametric Survival Analysis Using Stata: Beyond the Cox Model, which provides a general equation (in page 110) using ln t, z1 and z2 but I am confused about how to obtain z1 and z2 for computing my log cumulative hazard at a specific time point. From page 110 :
generate lnH = _b[_cons] + _rcs1 * _b[_rcs1] + _rcs2 * _b[_rcs2] + _rcs3 * _b[rcs3]
Specifically I would like to ask where can I obtain the estimates for _b[rcs1], _b[_rcs2] and _b[_rcs3] for the above model in order to write out the log cumulative hazard function for the model above.
Any leads are most appreciated!
Thank you very much.
Manee
Comment