ld.with(chopsticks)
ld.with()所属R语言包:chopsticks
function to calculate the LD measures of specific SNPs against
函数来计算具体的SNPs劳工处措施对
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This function calculates the LD measures ($r^2$, D', LOD) of specific SNPs against other SNPs.
此函数计算具体的单核苷酸多态性的LD措施,对其他SNPs(R ^ 2 $,D的LOD)。
用法----------Usage----------
ld.with(data, snps, include.itself = as.logical(length(snps) - 1), signed.r = NULL)
参数----------Arguments----------
参数:data
either a snp.dprime-class object or a snp.matrix-class object
snp.dprime-class对象或snp.matrix-class对象
参数:snps
A list of snps, some of which are found in data
单核苷酸多态性的名单,其中一些被发现data
参数:include.itself
Whether to include LD measures of SNPs against itself - it is FALSE for one SNP, since in that case, the result is known and trivial; but otherwise TRUE
是否包括单核苷酸多态性对本身的LD措施 - 它是一个SNP虚假的,因为在这种情况下,其结果被称为和琐碎;但否则真
参数:signed.r
Logical, whether to output signed r or $r^2$
逻辑,是否输出签署r或$ R ^ 2元
Details
详情----------Details----------
Not all combinations of the include.itself and signed.r make sense, nor fully operational.
不是所有的组合include.itself和signed.r意义,也没有充分运作。
值----------Value----------
The returned value is somewhat similiar to a snp.dprime object, but not the same. It is a list of 3 named matrices dprime, rsq2 (or r depending on the input), lod.
返回的值是有点同级snp.dprime对象,但并不相同。这是一个3名为矩阵列表dprime,rsq2(或r根据输入),lod。
警告----------Warning----------
Because this is really two functions rolled into one, depending on the class of data, not all combinations of the include.itself and signed.r make sense, nor fully operational.
因为这是两个功能集于一身,根据类data,并非所有的组合include.itself和signed.r意义,也没有充分运作。
Also, the two versions have slightly different idea about invalid values, e.g. the LOD value for a SNPs against itself, or $r^2$ for two monomorphic snps (such as one against itself).
此外,这两个版本有无效值略有不同的想法,例如: 1个SNP位点的LOD值对本身,或$ R ^ 2元两个单形单核苷酸多态性(如对本身)。
注意----------Note----------
The ld.with function started its life as an extractor function to take the output of ld.snp, a snp.dprime-class object, to rearrange it in a more convenient form to focus on the LD's against specific SNPs, but then evolved to take a snp.matrix-class object alternatively and perform the same task directly and more efficiently.
ld.with函数开始它的生命作为提取功能,采取输出ld.snp,snp.dprime-class对象,它在一个更方便的形式重新把重点放在针对特定的SNPs的LD,但后来演变或者采取snp.matrix-class对象和直接,更有效地执行相同的任务。
作者(S)----------Author(s)----------
Hin-Tak Leung <a href="mailto:htl10@users.sourceforge.net">htl10@users.sourceforge.net</a>
参见----------See Also----------
ld.snp, snp.dprime-class
ld.snp,snp.dprime-class
举例----------Examples----------
data(testdata)
snps10 <- Autosomes[1:10,1:10]
obj.snp.dprime <- ld.snp(snps10)
# result1 and result2 should be almost identical[RESULT1和RESULT2应该是几乎相同的]
# except where noted in the warning section above:[除了在上述警告节指出:]
result1 <- ld.with(obj.snp.dprime, colnames(snps10))
result2 <- ld.with(snps10, colnames(snps10))
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|