Fit a Cox model via the Global Adaptive Generative Adjustment algorithm. Part of this function refers to the coxphfit function in MATLAB 2016b.
cpp_COX_gaga(
X,
y,
cens,
alpha = 2,
itrNum = 50L,
thresh = 0.001,
flag = TRUE,
lamda_0 = 0.5,
fdiag = TRUE,
subItrNum = 20L
)
Coefficient vector
Input matrix, of dimension nobs*nvars; each row is an observation.
If the intercept term needs to be considered in the estimation process, then the first column of X
must be all 1s.
A n*1 matrix, indicating the survival time;
A n*1 matrix, consists of 0 and 1, 1 indicates that the row of data is censored, 0 is opposite.
Hyperparameter. The suggested value for alpha is 2 or 3.
Maximum number of iteration steps. In general, 20 steps are enough.
Convergence threshold for beta Change, if max(abs(beta-beta_old))<threshold
, return.
It identifies whether to make model selection. The default is TRUE
.
The initial value of the regularization parameter for ridge regression.
It identifies whether to use diag Approximation to speed up the algorithm.
Maximum number of steps for subprocess iterations.