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

R语言 MANOR包 to.flag()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-26 00:14:26 | 显示全部楼层 |阅读模式
to.flag(MANOR)
to.flag()所属R语言包:MANOR

                                        Create an object of type flag
                                         创建一个标志类型的对象

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

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

A flag object is a list which contains essentially a function (flag action) and a character, optionally arguments to be passed to the function. We make the distinction between two different flag types, corresponding to two different purposes: - permanent flags identify poor quality spots or clones and remove them from further analysis (eg spots with low signal to noise ratio) - temporary flags identify spots or clones that have not to be taken into account for the computation of a (scaling) normalization coefficient (eg X chromosome in case of sex mismatch)
一个flag对象是一个列表,其中包含本质上是一个函数(旗行动)和一个字符,可选参数传递给函数。我们让两个不同的标志类型,对应两种不同的目的之间的区别: - 永久性标志识别质量低劣景点或克隆,并从他们进一步分析(如低信号信噪比点) - 临时标志识别有斑点或克隆不考虑计算(缩放)归一化系数(如X染色体在性别错配的情况下)


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


to.flag(FUN, char=NULL, args=NULL, type="perm.flag", label=NULL)



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

参数:FUN
a R function to be applied to an arrayCGH, and optionally other arguments. If char is not NULL, must return a list of spots (lines of arrayCGH$arrayValues) to be flagged out; if char==NULL, must return an object of type arrayCGH
arrayCGH,可选其他参数被应用到研发功能。如果char是不是NULL,必须返回一个列表点标记出(arrayCGH$arrayValues线);如果char==NULL,必须返回一个对象类型arrayCGH


参数:char
a character value to identify flagged spots; defaults to NULL
为NULL的默认字符值识别标记点;


参数:args
a list of further arguments to be passed to FUN; defaults to NULL (ie arrayCGH is the only argument to FUN)
通过进一步论证列表FUN;默认为NULL(即arrayCGHFUN是唯一的参数)


参数:type
a character value defaulting to "perm.flag" which makes the distinction between permanent flags (type="perm.flag") and temporary flags (type="temp.flag")  
一个字符值,默认为“perm.flag”,这使永久性标志(类型=的“perm.flag”)和临时标志之间的区别(类型=的“temp.flag”)


参数:label
a character value for flag labelling
为标志的标签字符值


Details

详情----------Details----------

If flag$char is null, flag$FUN is supposed to return a arrayCGH object; if it is not null, flag$FUN is supposed to return a list of spots to be flagged with flag$char.
flag$char如果是空的,flag$FUN应该返回一个arrayCGH对象,如果它不为空,flag$FUN应该返回一个点的名单,以标记 flag$char。


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

An object of class flag.
对象类flag。


注意----------Note----------

People interested in tools for array-CGH analysis can
阵列比较基因组杂交分析工具有兴趣的人可以


作者(S)----------Author(s)----------


Pierre Neuvial, <a href="mailto:manor@curie.fr">manor@curie.fr</a>.



参见----------See Also----------

flag.arrayCGH, norm.arrayCGH
flag.arrayCGH,norm.arrayCGH


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


### creation of a permanent flag:[#建立一个永久性的标志:]
## flag spots with low signal to noise ratios[#标志点低信号噪声比]
SNR.FUN <- function(arrayCGH, snr.thr)
    which(arrayCGH$arrayValues$F2 < arrayCGH$arrayValues$B2+log(snr.thr, 2))
SNR.char <- "B"
SNR.flag <- to.flag(SNR.FUN, SNR.char, args=alist(snr.thr=3))

### creation of a permanent flag returning an arrayCGH object:[#创建永久性标志返回arrayCGH对象的:]
## correct log-ratios for spatial trend[#正确的登录率的空间趋势]

global.spatial.FUN <- function(arrayCGH, var)
  {
    Trend <- arrayTrend(arrayCGH, var, span=0.03, degree=1,
iterations=3, family="symmetric")
    arrayCGH$arrayValues[[var]] <- Trend$arrayValues[[var]]-Trend$arrayValues$Trend
    arrayCGH
  }
global.spatial.flag <- to.flag(global.spatial.FUN, args=alist(var="LogRatio"))

### creation of a temporary flag:[#创建一个临时标志:]
## exclude sexual chromosomes from signal scaling[#排除信号缩放性染色体]
chromosome.FUN <- function(arrayCGH, var)
  which(!is.na(match(as.character(arrayCGH$arrayValues[[var]]), c("X", "Y"))))
chromosome.char <- "X"
chromosome.flag <- to.flag(chromosome.FUN, chromosome.char, type="temp.flag",
args=alist(var="Chromosome"))

data(spatial)

SNR.flag$args$snr.thr &lt;- 3                   ## set SNR threshold[#设置的信噪比门限]
gradient &lt;- flag.arrayCGH(SNR.flag, gradient)    ## apply SNR.flag to array CGH[#申请SNR.flag的array CGH]

gradient <- flag.arrayCGH(global.spatial.flag, gradient)

gradient <- flag.arrayCGH(chromosome.flag, gradient)

summary.factor(gradient$arrayValues$Flag)   ## permanent flags[#永久性标志]
summary.factor(gradient$arrayValues$FlagT)  ## temporary flags[#临时标志]

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-2-4 06:49 , Processed in 0.027903 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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