Computing engine behind sclr
.
sclr_fit(
y,
x,
tol = 10^(-7),
algorithm = c("newton-raphson", "gradient-ascent"),
nr_iter = 2000,
ga_iter = 2000,
n_conv = 3,
conventional_names = FALSE,
seed = NULL
)
A vector of observations.
A design matrix.
Tolerance.
Algorithms to run. "newton-raphson" or "gradient-ascent". If a character vector, the algorithms will be applied in the order they are present in the vector.
Maximum allowed iterations for Newton-Raphson.
Maximum allowed iterations for gradient ascent.
Number of times the algorithm has to converge (to work around local maxima).
If TRUE
, estimated parameter names will be
(Baseline), (Intercept) and the column names in the model matrix. Otherwise
- lambda, beta_0 and beta_ prefix in front of column names in the model
matrix.
Seed for the algorithms.
The likelihood maximisation can use the Newton-Raphson or the gradient ascent algorithms.