'grplasso'软件包有很多问题。当我想计算AIC时,我遇到了这个错误。如何从grplasso函数提取GLM模型?
data(splice)
## Define a list with the contrasts of the factors
contr <- rep(list("contr.sum"), ncol(splice) - 1)
names(contr) <- names(splice)[-1]
## Fit a logistic model
fit.splice <- grplasso(y ~ ., data = splice, model = LogReg(), lambda = 20, center = TRUE, standardize = TRUE)
AIC(fit.splice)
UseMethod(“ logLik”)中的错误:'logLik'没有适用的方法 应用于“ grplasso”类的对象