找回密码
 注册
查看: 457|回复: 0

R语言 GGtools包 probeLocations()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-25 19:49:50 | 显示全部楼层 |阅读模式
probeLocations(GGtools)
probeLocations()所属R语言包:GGtools

                                         utilities for annotation acquisition with smlSet instances
                                         注释收购公用事业smlSet实例

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

utilities for annotation acquisition with smlSet instances
注释收购公用事业smlSet实例


用法----------Usage----------


probeLocations(sms, extend=0)
probeSequences(sms)
probeChromosomes(sms)
snpLocations(sms, snpLocGRanges, grsnpid = "RefSNP_id")
proximityList(sms, smlind=1, snpLocGRanges, grsnpid = "RefSNP_id", probeLocExtend=0,
  glocTransform=function(x)x)
restrictProbesToChrom(smlSet, chrom)
getGene2SnpList(sms, chr, genome, radius=50000,
   additionalSNPGR=NULL, useTxDb=FALSE)



参数----------Arguments----------

参数:sms
instance of smlSet-class, which should have an annotation slot correctly identifying an AnnotationDbi-compliant annotation package for expression probes  
smlSet-class,它应该有正确识别表达探针AnnotationDbi兼容的注解包注释插槽实例


参数:smlSet
see sms above
sms上面看到


参数:extend
numeric value to extend regions by, using algebra of + for IRanges instances
数值以扩展区域,使用IRanges实例+代数


参数:snpLocGRanges
an instance of GRanges-class with numeric tokens for dbSNP identifiers as used in SNPlocs.* packages. The identifiers are in elementMetadata(snpLocGRanges)[[grsnpid]]  
GRanges-class与在SNPlocs dbSNP的标识符数字标记。*包中的一个实例。标识符是在elementMetadata(snpLocGRanges)[grsnpid]


参数:grsnpid
a character string naming the elementMetadata element holding the SNP identifiers, as returned by a getSNPlocs with as.GRanges=TRUE
字符串命名的elementMetadata的元素控股的SNP标识符,返回与as.GRanges = TRUE,1 getSNPlocs


参数:smlind
proximityList will work for only one element of smList(sms); this argument picks it out.
proximityList工作只有一个元素smList(sms)这种说法捡起来。


参数:probeLocExtend
numeric, by which we extend (using ranges()+extend) the ranges of the resulting GRanges for probe locations
数字,我们扩展(使用范围()+延长)探针位置所产生的农庄范围


参数:glocTransform
alters the probeLocations(sms) GRanges to define SNP proximity for inclusion in gene-snp association list
改变probeLocations(sms)农庄定义的SNP靠近列入基因的SNP关联列表


参数:chrom
chromosome token
染色体令牌


参数:chr
chromosome token, must be in 1:22
染色体标记,必须在1:22


参数:genome
an element of c("hg18", "hg19")
c("hg18", "hg19")元素


参数:radius
numeric, how far upstream and downstream from gene interval to check for SNP, in bases
数字,上游和下游基因间隔多远检查的SNP碱基,


参数:additionalSNPGR
a GRanges with range information on additional SNP not found in Bioconductor resources, for example those obtained by imputation.  Must have structure similar to that returned by the genome-appropriate call to getSNPlocs.
额外的SNP信息的使用范围1格朗未发现Bioconductor资源,例如由归集获得的。必须有适当的基因组到getSNPlocs打来返回的结构相似。


参数:useTxDb
logical, if TRUE take the gene locations for probes by translating to Entrez genes and using the genome-appropriate TxDb.
逻辑,如果为TRUE翻译Entrez的基因,并用适当的基因组TxDb基因探针的位置。


值----------Value----------

probeLocations and snpLocations return GRanges instances.  names() of the probeLocations result gives the probe identifiers.  SNP identifiers are in elementMetadata.
probeLocations和snpLocations返回农庄的实例。名称(的probeLocations结果)给出了探针标识。单核苷酸多态性的标识符在elementMetadata的。

probeSequences() works when a PROBESEQUENCE custom mapping is available in the AnnotationDbi compliant package identified in annotation(sms)
probeSequences()工作时PROBESEQUENCE自定义映射annotation(sms) AnnotationDbi符合确定的包


举例----------Examples----------


data(smlSet.example)
library(illuminaHumanv1.db)
probeLocations(smlSet.example)
spac = "SNPlocs.Hsapiens.dbSNP.20100427"
if (spac %in% (IP <- installed.packages()[,1])) {
library(spac, character.only=TRUE)
c20 = getSNPlocs("ch20", as.GRanges=TRUE)
seqlevels(c20)[20] = "20"
if (!exists("hmceuB36.2021")) hmceuB36.2021 <- getSS("GGtools", c("20", "21"))
h20 = hmceuB36.2021[ chrnum("20"), ] # restrict smList[限制smList]
pcc = probeChromosomes(h20)
p20 = featureNames(h20)[ which(pcc == "20") ] # for NA[关于NA]
h20 = h20[ probeId(p20[1:20]), ]
h20 = dropMonomorphies(h20)
pl = proximityList( h20, 1, c20)
cat("count SNPs in gene region\n")
print(sapply(pl, length))
pl2 = proximityList( h20, 1, c20, glocTransform = function(x) {
    ranges(x) = ranges(x)+50000 # extend gene interval 50kb on each end[每年年底延长基因间隔50KB]
    x})
pl3 = proximityList( h20, 1, c20, probeLocExtend=50000)
cat("count SNPs in gene region extended by 50k at each end\n")
print( sapply(pl2, length))
td = tempdir()
curd = getwd()
setwd(td)
applier = lapply
if ("multicore" %in% IP) {
    library(multicore)
    applier=mclapply
    }
et1 = eqtlTests( h20, ~male, geneApply=applier )
sco1 = lapply(1:length(pl), function(x) et1[ rsid(pl[[x]]), probeId(names(pl)[x]) ])
print(sapply(sco1, sapply, max))
sco2 = lapply(1:length(pl2), function(x) et1[ rsid(pl2[[x]]), probeId(names(pl2)[x]) ])
print(sapply(sco2, sapply, max))
}

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2025-5-25 01:46 , Processed in 0.022952 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表