snp.lhs.estimates(snpStats)
snp.lhs.estimates()所属R语言包:snpStats
Logistic regression with SNP genotypes as dependent variable
与SNP的基因型为因变量的Logistic回归
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Under the assumption of Hardy-Weinberg equilibrium, a SNP genotype is a binomial variate with two trials for an autosomal SNP or with one or two trials (depending on sex) for a SNP on the X chromosome. With each SNP in an input "SnpMatrix" as dependent variable, this function fits a logistic regression model. The Hardy-Weinberg assumption can be relaxed by use of a "robust" option.
Hardy-Weinberg平衡的前提下,一个SNP基因型是一个常染色体SNP的两个试验或二项式变量与一个或两个试验为X染色体上的SNP(基于性别而定)。每个SNP的输入"SnpMatrix"作为因变量,此功能符合逻辑回归模型。 Hardy-Weinberg平衡假设使用一个“强有力的”选项可以放宽。
用法----------Usage----------
snp.lhs.estimates(snp.data, base.formula, add.formula, subset, snp.subset,
data = sys.parent(), robust = FALSE, uncertain = FALSE,
control=glm.test.control(maxit=20, epsilon=1.e-5,R2Max=0.999))
参数----------Arguments----------
参数:snp.data
The SNP data, as an object of class "SnpMatrix" or "XSnpMatrix"
SNP数据,如对象类"SnpMatrix"或"XSnpMatrix"
参数:base.formula
A formula object describing a base model containing those terms which are to be fitted but for which parameter estimates are not required (the dependent variable is omitted from the model formula)
一个formula对象描述了一个示范碱基,载有这些条款,这是要装的,但参数估计不需要(因变量的模型公式中省略)
参数:add.formula
A formula object describing the additional terms in the model for which parameter estimates are required (again, the dependent variable is omitted)
一个formula对象描述模型的参数估计需要的附加条款(再次省略,因变量)
参数:subset
An array describing the subset of observations to be considered
一个数组,描述观测的子集,被视为
参数:snp.subset
An array describing the subset of SNPs to be considered. Default action is to test all SNPs.
要考虑的一个数组描述的SNPs的子集。默认动作是测试所有的SNPs。
参数:data
The data frame in which base.formula, add.formula and subset are to be evaluated
base.formula,add.formula和subset是被评估的数据框
参数:robust
If TRUE, Hardy-Weinberg equilibrium will is not assumed in calculating the variance-covariance matrix of parameter estimates
TRUE如果,Hardy-Weinberg平衡将不承担计算参数估计的协方差矩阵
参数:uncertain
If TRUE, uncertain genotypes are used and scored by their posterior expectations. Otherwise they are treated as missing. If set, this option forces robust variance estimates
如果TRUE,不确定的基因型使用后期望取得的。否则,他们被视为失踪。如果设置,这个选项强制robust方差估计
参数:control
An object giving parameters for the IRLS algorithm fitting of the base model and for the acceptable aliasing amongst new terms to be tested. See glm.test.control
对象给予示范碱基IRLS算法拟合和参数之间要测试新条款的接受走样。看到glm.test.control
Details
详情----------Details----------
The model fitted is the union of the base.formula and add.formula models, although parameter estimates (and their variance-covariance matrix) are only generated for the parameters of the latter. The "robust" option causes a Huber-White "sandwich" estimate of the variance-covariance matrix to be used in place of the usual inverse second derivative matrix of the log-likelihood (which assumes Hardy-Weinberg equilibrium). If a data argument is supplied, the snp.data and data objects are aligned by rowname. Otherwise all variables in the model formulae are assumed to be stored in the same order as the columns of the snp.data object.
模型拟合是工会base.formula和add.formula模型,虽然只有后者的参数生成的参数估计值(和其协方差矩阵)。 “稳健”的选项,导致1胡伯白色的“三明治”的协方差矩阵的估计,在平常的逆log的可能性(假设Hardy-Weinberg平衡)的二阶导数矩阵的地方使用。如果data参数提供,snp.data和data对象由rowname的对齐。否则,所有的模型公式中的变量被假设为在相同的顺序列snp.data对象存储。
值----------Value----------
An object of class GlmEstimates
一个对象的类GlmEstimates
注意----------Note----------
A factor (or several factors) may be included as arguments to the function strata(...) in the base.formula. This fits all interactions of the factors so included, but leads to faster computation than fitting these in the normal way. Additionally, a cluster(...) call may be included in the base model formula. This identifies clusters of potentially correlated observations (e.g. for members of the same family); in this case, an appropriate robust estimate of the variance-covariance matrix of parameter estimates is calculated.
可以作为函数的参数中包含的一个因素(或几个因素)strata(...)base.formula的。这符合包括所有因素相互作用,但比装修这些在正常的方式,以更快的计算。此外,cluster(...)通话可能被包括在基本模型公式。这标识聚类潜在的相关意见(如为同一家庭的成员),在这种情况下,一个适当的参数估计的方差 - 协方差矩阵的鲁棒估计计算。
If uncertain genotypes (e.g. as a result of imputation) are used, the interpretation of the regression coefficients is questionable.
如果不确定的基因型(例如,作为一个结果归责),回归系数的解释是值得商榷的。
A known bug is that the function fails when no data argument is supplied and the base model formula contains no variables (~1). A work-round is to create a data frame to hold the variables in the models and pass this as data=.
一个已知的bug是该函数失败时没有data参数提供示范碱基公式包含任何变量(~1)。一个工作轮是创建一个数据框保存在模型中的变量,并通过data=。
作者(S)----------Author(s)----------
David Clayton <a href="mailto:david.clayton@cimr.cam.ac.uk">david.clayton@cimr.cam.ac.uk</a>
参见----------See Also----------
GlmEstimates-class, snp.lhs.tests
GlmEstimates-class,snp.lhs.tests
举例----------Examples----------
data(testdata)
test1 <-
snp.lhs.estimates(Autosomes[,1:10], ~cc, ~region, data=subject.data)
test2 <-
snp.lhs.estimates(Autosomes[,1:10], ~strata(region), ~cc,
data=subject.data)
test3 <-
snp.lhs.estimates(Autosomes[,1:10], ~cc, ~region, data=subject.data, robust=TRUE)
test4 <-
snp.lhs.estimates(Autosomes[,1:10], ~strata(region), ~cc,
data=subject.data, robust=TRUE)
test5 <- snp.lhs.estimates(Autosomes[,1:10], ~region+sex, ~cc, data=subject.data, robust=TRUE)
print(test1)
print(test2)
print(test3)
print(test4)
print(test5)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|