powered by
Constraint on the maximum number of covariates to be used in the model.
k_max(k)
A holistic generalized model constraint, object inheriting from class "hglmc".
"hglmc"
an positive integer with \(k \leq k_{max}\) giving the maximum number of covariates to be used in the model.
Other Constraint-Constructors: group_equal(), group_inout(), group_sparsity(), include(), linear(), lower(), pairwise_sign_coherence(), rho_max(), sign_coherence(), upper()
group_equal()
group_inout()
group_sparsity()
include()
linear()
lower()
pairwise_sign_coherence()
rho_max()
sign_coherence()
upper()
dat <- rhglm(100, c(1, 2, -3, 4, 5, -6)) hglm(y ~ ., constraints = k_max(3), data = dat)
Run the code above in your browser using DataLab