hanaml.CoxProportionalHazard.Rdhanaml.CoxProportionalHazard is an R wrapper for SAP HANA PAL Cox proportional hazard model.
hanaml.CoxProportionalHazard( data = NULL, key = NULL, label = NULL, status = NULL, features = NULL, formula = NULL, tie.method = NULL, max.iter = NULL, tol = NULL, significance.level = NULL, calculate.hazard = NULL, output.fitted = NULL )
| data |
|
|---|---|
| key |
|
| label |
|
| status |
|
| features |
|
| formula |
|
| tie.method |
|
| max.iter |
|
| tol |
|
| significance.level |
|
| calculate.hazard |
|
| output.fitted |
|
Return a "CoxProportionalHazard" object with following values:
statistics: DataFrame
Regression-related statistics, like mean square error, F-statistics, etc.
coefficients: DataFrame
Fitted regression coefficients for the Cox PH model.
covariance: DataFrame
Covariance values between features.
hazard: DataFrame
Calculated cumulative baseline hazard function and survival function.
fitted: DataFrame
Predicted linear predictors and exponential responses in risk space.
Cox proportional hazard model is a special generalized linear model. It is a well-known realization-of-survival model that demonstrates failure or death at a certain time
Input DataFrame data:
> data$Collect() ID TIME STATUS X1 X2 1 1 4 1 0 0 2 2 3 1 2 0 3 3 1 1 1 0 4 4 1 0 1 0 5 5 2 1 1 1 6 6 2 1 0 1 7 7 3 0 0 1
Call the function:
cph <- hanaml.CoxProportionalHazard(data = data, key = "ID", label = "TIME", status = "STATUS", tie.method = "efron", calculate.hazard = TRUE, output.fitted = TRUE)
Output:
> cph$coefficients VARIABLE_NAME MEAN COEFFICIENT SE SCORE PROBABILITY CI_LOWER CI_UPPER 1 X1 0.7142857 0.7811819 0.7975689 0.9794538 0.3273558 -0.7820244 2.344388 2 X2 0.4285714 0.9337832 1.4081100 0.6631465 0.5072367 -1.8260617 3.693628