Survival analysis models and utilities, written in Julia.
SurvivalModels.jl is part of the JuliaSurv ecosystem. It provides a consistent interface for nonparametric estimation and testing, semiparametric Cox regression, and fully parametric survival models.
The package is available from Julia's General registry:
using Pkg
Pkg.add("SurvivalModels")Then load it with:
using SurvivalModels- Kaplan–Meier estimation, including Greenwood confidence intervals.
- Survival and cumulative-hazard prediction at observed or user-supplied times.
- Two- and multi-group log-rank tests.
- Stratified log-rank tests with tied-event variance correction.
- Cox proportional hazards regression through the formula interface.
- Breslow baseline cumulative-hazard estimation.
- Coefficients, standard errors, covariance matrices, confidence intervals, coefficient tables, log partial likelihood, AIC, AICc, and BIC.
- Prediction of linear predictors, relative risks, term contributions, cumulative hazards, and survival probabilities.
- Prediction on new data using the schema stored during fitting.
- General Hazard (GH), Proportional Hazards (PH), Accelerated Failure Time (AFT), and Accelerated Hazards (AH) model structures.
- Flexible continuous baseline distributions through the
Distributions.jlinterface. - Formula-based fitting, statistical inference, information criteria, and coefficient tables.
- Cumulative-hazard and survival prediction for training or new data.
- Simulation from GH, PH, AFT, and AH models.
- Harrell's concordance index for Cox models.
- IPCW Brier scores and integrated Brier scores for Cox and parametric models.
- Standard
fit,predict,coef,vcov,confint, and related interfaces fromStatsBase.jl,StatsAPI.jl, andStatsModels.jl. DataFrames.jland@formula(Surv(time, status) ~ predictors)workflows.
See the stable documentation for examples and the complete API.
Questions, bug reports, feature requests, and pull requests are welcome through the repository's issue tracker. General collaborative guidelines are available from ColPrac.