CamDavidsonPilon / lifelines

Survival analysis in Python
lifelines.readthedocs.org
MIT License
2.32k stars 551 forks source link

Why use X_norm instead of X directly? #1520

Open GaoJiannn opened 1 year ago

GaoJiannn commented 1 year ago

X_norm = pd.DataFrame( utils.normalize(X.values, self._norm_mean.values, self._norm_std.values), index=X.index, columns=X.columns )

    params_, ll_, variance_matrix_, baseline_hazard_, baseline_cumulative_hazard_, model = self._fit_model(
        X_norm,
        T,
        E,
        weights=weights,
        entries=entries,
        fit_options=utils.coalesce(fit_options, dict()),
        initial_point=initial_point,
        show_progress=show_progress,
    )

X_norm is used in the above code, does it mean that the expression of the hazard rate is: image If I want the hazard rate expression to be: image Can I change X_norm to X in the above code? Will there be any other effects?