km function

Fit a Kaplan-Meier model