Calculate the cumulative hazard over [0, tmax] from piecewise constant model.

pwe_Hu(time, cut.pts, haz.rates)

Arguments

time

Time-point at which cumulative hazard evaluated, H(time) = int_0^time h(u) du.

cut.pts

Vector of cut points.

haz.rates

Vector of hazard rates (must have one element more than the cut.pts vector).

Value

numeric estimate of the hazard over [0, tmax]