This function calculates the E step in a quicker way, without taking all the derivatives of the Laplace transform.
Such closed form solutions are only available for the gamma distribution (with or without left truncation) and
for the inverse Gaussian distribution (without left truncation).
For a data set with K
clusters,
fast_Estep(c, c_lt = 0, delta, alpha, bbeta, pvfm, dist)
Vector of length K
of cumulative hazards, i.e. total accumulated hazards within a cluster
Vector of length K
of cumulative hazard from 0 to the left truncation time
Vector of integers of length K
of the number of events for each cluster
Parameters of the frailty distribution
Parameter for the PVF distribution, only matters in that case
One of 0 (for gamma), 1 (for stable) or 2 (for PVF)
A K x 4
matrix where the first column and the second column are the numerators
and the denominators of the frailty fraction, the third is the log-likelihood contribution, and the
last column is the expectation of the squared frailty (only used in calculating the information matrix)