[英]is p-value deprecated in h2o glm
Elasticnet中是否弃用了p值? 以下参考资料显示了系数中的p值http://docs.h2o.ai/h2o/latest-stable/h2o-docs/data-science/glm.html
但是当我执行以下命令时我看不到p值
head(elastic_net_best_model@model$coefficients_table)
Coefficients: glm coefficients
names coefficients standardized_coefficients
仅当将compute_p_values设置为true时,才会计算p值,并且这仅在没有正则化的情况下才有效,这需要lambda = 0
举个例子,
library(h2o)
h2o.init()
x<-as.h2o(iris)
xg<-h2o.glm(y="Sepal.Length",training_frame=x,compute_p_values=TRUE,lambda=0)
head(xg@model$coefficients_table)
这给出了输出:
Coefficients: glm coefficients
names coefficients std_error z_value p_value standardized_coefficients
1 Intercept 2.171266 0.279794 7.760227 0.000000 6.425687
2 Species.versicolor -0.723562 0.240169 -3.012721 0.003060 -0.723562
3 Species.virginica -1.023498 0.333726 -3.066878 0.002584 -1.023498
4 Sepal.Width 0.495889 0.086070 5.761466 0.000000 0.216141
5 Petal.Length 0.829244 0.068528 12.100867 0.000000 1.463863
6 Petal.Width -0.315155 0.151196 -2.084418 0.038888 -0.240223
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.