16 int l = num_elements(p);
21 cum_p[2:i] = cumulative_sum(p[1:(i-1)]);
22 h[1:i] = p[1:i] .* inv(1 - cum_p);
49 h_shifted[2:l] = h[1:(l-1)];
51 ch = log1m(h_shifted);
52 ch = cumulative_sum(ch);
vector prob_to_hazard(vector p)
vector cumulative_converse_log_hazard(vector h, int l)
vector hazard_to_log_prob(vector h, int l)