According to the docs
https://scikit-survival.readthedocs.io/en/stable/api/generated/sksurv.linear_model.CoxPHSurvivalAnalysis.html#sksurv.linear_model.CoxPHSurvivalAnalysis.predict_survival_function
it returns an array of probabilities of the survival function . When plotting this , which time frame is the x axis ?
There is a give plotting example on the docs page as below
for fn in surv_funcs:
plt.step(fn.x, fn(fn.x), where="post")
plt.ylim(0, 1)
plt.show()
What is does this part describe (plt.step(fn.x, fn(fn.x), where="post")
)
This works for CoxPH or any survival model that assumes PH . The return array from predict_survival_function() in CoxPH will be an array that has both X and Y values For Random forest use :