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

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

[复制链接]
发表于 2012-2-25 13:53:27 | 显示全部楼层 |阅读模式
getBioColor(biovizBase)
getBioColor()所属R语言包:biovizBase

                                        Color scheme getter for biological data
                                         生物数据的颜色计划的getter

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

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

This function tries to get default color scheme either from fixed palette or options for specified data set, usually just biological data.
这个函数试图从固定的调色板或指定的数据集,通常只是生物数据的选项,默认的配色方案。


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


getBioColor(type = c("DNA_BASES_N", "DNA_BASES", "DNA_ALPHABET",
                     "RNA_BASES_N", "RNA_BASES", "RNA_ALPHABET",
                     "IUPAC_CODE_MAP", "AMINO_ACID_CODE", "AA_ALPHABET",
                     "STRAND", "CYTOBAND"),
            source = c("option", "default"))



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

参数:type
Color set based on which you want to get.  
根据你想要得到的颜色设置。


参数:source
"option" tries to get color scheme from Options. This allow user to edit the color globally. "default" gets fixed color scheme.  
“选项”,试图从Options配色方案。这允许用户在全球范围内编辑的颜色。 “默认”获取固定的配色方案。


Details

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

Most data set specified in the type argument are defined in Biostrings package, such as "DNA_BASES", "DNA_ALPHABET", "RNA_BASES", "RNA_ALPHABET", "IUPAC_CODE_MAP", "AMINO_ACID_CODE", "AA_ALPHABET", please check the manual for more details.
大多数数据集在Biostrings包,如的“DNA_BASES”,“DNA_ALPHABET”,“RNA_BASES”,“RNA_ALPHABET”,“IUPAC_CODE_MAP”,“AMINO_ACID_CODE”,“AA_ALPHABET”,定义在指定的类型参数,请检查手册更多详情。

"DNA_BASES_N" is just "DNA_BASES" with extra "N" used in certain cases, like the result from applyPileup in Rsamtools package. We start with the five most used nucleotides, A,T,C,G,N, In genetics, GC-content usually has special biological significance because GC pair is bound by three hydrogen bonds instead of two like AT pairs. So it has higher thermostability which could result in different significance, like higher annealing temperature in PCR. So we hope to choose warm color for G,C and cold color for A,T, and a color in between to represent N.  They are chosen from diverging color set of color brewer. So we should be able to easily tell the GC enriched region. This set of color also passed vischeck for colorblind people.
“DNA_BASES_N”只不过是“DNA_BASES”额外的“N”在某些情况下使用,像applyPileup的Rsamtools在包的结果。我们先从最常用的五个核苷酸,A,T,C,G,N,在遗传学上,GC-content通常具有特殊的生物学意义,因为GC配对是由三个而不是两个氢像AT对债券的约束。因此,它具有较高的热稳定性,这可能会导致不同的意义,如较高的退火温度在PCR。因此,我们希望选择G,C和冷色系A,T,和之间的颜色代表N的暖色。他们选择了从color brewer设置不同的颜色。因此,我们应该能够很容易地告诉GC富集区。这组颜色的色盲的人也通过vischeck。

In GRanges object, we have strand which contains three levels, +, -, *. We are using a qualitative color set from Color     Brewer. This color set pass the colorblind test. It should be a safe color set to use to color strand.
GRanges对象,我们有strand其中包含三个层次,+, - ,*。我们使用的是从Color     Brewer设置了质的颜色。这种颜色的设置,通过色盲测试。它应该是一个安全的颜色设置使用彩色链。

For most default color scheme if they are under 18, we are trying to use package dichromat to set color for color blind people. But for data set that contains more than 18 objects, it's not possible to assign colorblind-safe color to them anymore. So we need to repeat some color. It should not matter too much, because even normal people cannot tell the difference anymore.
对于大多数默认的配色方案,如果他们在18岁以下,我们试图用包dichromat为色盲的人的颜色。但数据集,其中包含超过18个对象,这是不可能的分配色盲安全的色彩给他们了。因此,我们需要重复一些色彩。它不应该的问题太多,因为即使是正常的人不能分辨了。

Here are the definition for the data sets.
下面是数据集的定义。

Contains A,C,T,G.
包含A,C,T,G。

This alphabet contains all letters from the IUPAC Extended Genetic Alphabet (see "?IUPAC_CODE_MAP") + the gap ("-") and the hard masking ("+") letters.      
这个字母表包含所有字母的IUPAC扩展遗传字母(见“IUPAC_CODE_MAP”)+(“ - ”)的差距和硬盘掩蔽(“+”),字母。

Contains A,C,T,G,N
包含A,C,T,G,N

Contains A,C,U,G,N
包含A,C,U,G,N

Contains A,C,T,G
包含A,C,T,G

This alphabet contains all letters from the IUPAC Extended Genetic Alphabet (see ?IUPAC_CODE_MAP) where "T" is replaced by "U" + the gap ("-") and the hard masking ("+") letters.
这个字母表中包含的IUPAC扩展遗传字母(见IUPAC_CODE_MAP?)“T”型,“U”型取代+的差距(“ - ”)的所有字母和硬盘掩蔽(“+”)字母。

The "IUPAC_CODE_MAP" named character vector contains the mapping from the IUPAC nucleotide ambiguity codes to their meaning.
“IUPAC_CODE_MAP”命名的特征向量包含的IUPAC核苷酸的模糊代码映射到它们的含义。

Single-Letter Amino Acid Code (see "?AMINO_ACID_CODE").
单字母氨基酸代码(见“?AMINO_ACID_CODE”)。

This alphabet contains all letters from the Single-Letter Amino Acid Code (see "?AMINO_ACID_CODE") + the stop ("*"), the gap ("-") and the hard masking ("+") letters      
这个字母表中包含氨基酸单字母代码(见“AMINO_ACID_CODE?”)+停止(“*”),差距(“ - ”)的所有字母和硬盘屏蔽(“” ;)字母

Contains "+", "-", "*"
包含"+", "-", "*"

Contains giemsa stain results:gneg, gpos25, gpos50, gpos75,         gpos100, gvar, stalk, acen. Color defined in package geneplotter.
包含Giemsa染色结果:gneg, gpos25, gpos50, gpos75,         gpos100, gvar, stalk, acen。包geneplotter定义的颜色。


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

A character of vector contains color(rgb), and the names of the vector is originally from the name of different data set. e.g. for DNA_BASES, it's just A,C,T,G. This allow users to get color for a vector of specified names. Please see the examples below.
向量的字符包含颜色(RGB),向量的名字最初是从不同的数据集的名称。例如DNA_BASES,它只是A,C,T,G。这使用户能够得到一个指定名称的向量的颜色。请参阅下面的例子。


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


Tengfei Yin



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


opts <- getOption("biovizBase")
opts$DNABasesNColor[1] <- "red"
options(biovizBase = opts)
## get from option(default)[#从选项(默认)]
getBioColor("DNA_BASES_N")
## get default fixed color[#默认固定的颜色。]
getBioColor("DNA_BASES_N", source = "default")
seqs <- c("A", "C", "T", "G", "G", "G", "C")
## get colors for a sequence.[#得到一个序列的颜色。]
getBioColor("DNA_BASES_N")[seqs]

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-1-25 05:15 , Processed in 0.019274 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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