我在用着SNPassoc用于查找数据 SNP 和连续变量结果之间关联的 R 包。我进行了分析并得到了结果;但是,我收到警告消息:
Warning in terms.formula(formula, data = data) :
'varlist' has changed (from nvar=3) to new 4 after EncodeVars() -- should no longer happen!
我的模型是:
model <- WGassociation (continuous variable ~ covariate +covariate+ covariate ,data= data)
model
我不知道这意味着什么,我应该担心还是忽略它?
你能帮我么?
此警告消息即将到来glm,其使用者为SNPassoc::WG 协会, 在 GitHub 上查看这一行.
警告消息表明它正在删除某些变量,因为它是模型中其他现有变量的线性组合。
要重现此警告,请尝试以下示例:
# data
x <- mtcars[, 1:4]
# run model, all good
glm(mpg ~ ., data = x)
# Call: glm(formula = mpg ~ ., data = x)
#
# Coefficients:
# (Intercept) cyl disp hp
# 34.18492 -1.22742 -0.01884 -0.01468
#
# Degrees of Freedom: 31 Total (i.e. Null); 28 Residual
# Null Deviance: 1126
# Residual Deviance: 261.4 AIC: 168
现在添加由现有变量构造的无用组合变量。
# make a combo var
cyldisp <- x$cyl + x$disp
# run model with combo var, now we get the warning
glm(mpg ~ . + cylmpg, data = x)
# Call: glm(formula = mpg ~ . + cyldisp, data = x)
#
# Coefficients:
# (Intercept) cyl disp hp cyldisp
# 34.18492 -1.22742 -0.01884 -0.01468 NA
#
# Degrees of Freedom: 31 Total (i.e. Null); 28 Residual
# Null Deviance: 1126
# Residual Deviance: 261.4 AIC: 168
# Warning message:
# In terms.formula(formula, data = data) :
# 'varlist' has changed (from nvar=4) to new 5 after EncodeVars() -- should no longer happen!
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)