rt <- read.csv("merged_matrix.csv",header = T,row.names = 1)
###构建模型
set.seed(10)
x=as.matrix(rt[,c(2:ncol(rt))])
y=data.matrix(rt$fustat)
x <- scale(x) # 标准化x
#y <- scale(y)
fit=glmnet(x, y, family = "binomial", maxit = 3000)
plot(fit, xvar = "lambda", label = TRUE)
cvfit = cv.glmnet(x, y, family="binomial", maxit = 30000)
Warning messages:
1: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
2: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
3: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
4: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
5: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
6: In lognet(xd, is.sparse, ix, jx, y, weights, offset, alpha, nobs, :
one multinomial or binomial class has fewer than 8 observations; dangerous ground
进行losso分析时一直跳出以上警告信息,最终制作出的图中AUC为1,请求各位大神的帮助。
相似问题