Skip to main content

Module cox

Module cox 

Source
Expand description

Cox proportional-hazards regression (ISL ch 11.5) — semiparametric hazard model h(t|x) = h₀(t)·exp(βᵀx), fit by maximizing the Breslow partial likelihood with Newton–Raphson. The p×p information-matrix solve reuses linear_algebra::cholesky (no new solver); Wald standard errors / p-values use statistics::distributions.

Structs§

CoxModel
A fitted Cox model.

Functions§

fit
Fit Cox PH of right-censored (times, event) on a row-major n × p covariate matrix. event[i] = true is an observed event, false is right-censoring. Fails closed: InvalidDimension, InsufficientData, Singular, NotConverged.