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

R语言 girafe包 AlignedGenomeIntervals-class()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-25 19:52:02 | 显示全部楼层 |阅读模式
AlignedGenomeIntervals-class(girafe)
AlignedGenomeIntervals-class()所属R语言包:girafe

                                        Class 'AlignedGenomeIntervals'
                                         类AlignedGenomeIntervals“

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

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

A class for representing reads from next-generation sequencing experiments that have been aligned to genomic intervals.
A类为代表的新一代测序实验已对齐基因间隔读取。


类的对象----------Objects from the Class----------

Objects can be created either by:
对象可以通过创建:

calls of the form new("AlignedGenomeIntervals", .Data, closed, ...).
调用形式new("AlignedGenomeIntervals", .Data, closed, ...)。

using the auxiliary function AlignedGenomeIntervals and supplying separate vectors of same length which hold the required information:<br> AlignedGenomeIntervals(start, end, chromosome, strand, reads,       matches, sequence)<br> If arguments reads or matches are not specified, they are assumed to be '1' for all intervals.
使用辅助功能AlignedGenomeIntervals和提供独立的向量长度相同,而持有所需的信息:参考AlignedGenomeIntervals(start, end, chromosome, strand, reads,       matches, sequence)参考,如果参数reads或matches不指定,他们被认为是1所有的时间间隔。

or, probably the most common way, by coercing from objects of class AlignedRead.
或者,可能是最常见的方式,强迫类AlignedRead的对象。


插槽----------Slots----------




.Data: two-column integer matrix, holding the
.Data:两列的整数矩阵,持有




sequence: character; sequence of the read aligned to
sequence:性格;序列对齐读




reads: integer; total number of reads that were
reads:整数;总数读取为




matches: integer; the total number of genomic intervals that reads which were aligned to this interval were aligned to. A value of '1' thus means that this read sequence
matches:整数;总数的读取基因组区间,这个区间对齐对齐。 1的值,从而意味着该读序列




organism: string; an identifier for the genome of which organism the intervals are related to. Functions making use of this slot require a specific annotation package org.<organism>.eg.db. For example if organism is 'Hs', the annotation package 'org.Hs.eg.db' is utilised by these functions. The annotation packages can be obtained from the
organism:字符串;一个有机体间隔有关的基因组的标识符。使用这种插槽的功能,需要特定的注解包org.<organism>.eg.db。例如,如果organism是HS,注释包org.Hs.eg.db“利用这些功能。注解包,可从




annotation: data.frame; see class
annotation:数据框;看到类




closed: matrix; see class
closed:矩阵;类




type: character; see class
type:字符;看到类




score: numeric; optional score for each aligned genome
score:数字;可选的得分为每个排列的基因组




id: character; optional identifier for each aligned
id:性格;可选的标识符每个对齐




chrlengths: integer; optional named integer vector of chromosome lengths for the respective genome; if present it is used in place of the chromosome lengths retrieved from the
chrlengths:整数,可选命名为各自的基因组染色体长度的整数向量,如果存在,它是在染色体长度的地方使用取自


延伸----------Extends----------

Class Genome_intervals-class, directly. Class Intervals_full, by class "Genome_intervals", distance 2.
类Genome_intervals-class,直接。类Intervals_full,由类“Genome_intervals”,距离为2。


方法----------Methods----------




coerce Coercion method from objects of class AlignedRead, which is defined in package ShortRead,
要挟对象类AlignedRead,胁迫方法在包中定义的ShortRead




coerce Coercion method from objects of class AlignedGenomeIntervals to objects of class
要挟类AlignedGenomeIntervals的对象强制方法类对象




coverage signature("AlignedGenomeIntervals"): computes the read coverage over all chromosomes. If the organism of the object is set correctly, the chromosome lengths are retrieved from the appropriate annotation package, otherwise the maximum interval end is taken to be the absolute length of that chromosome (strand).<br> The result of this method is a list and the individual list elements are of class Rle, a class for encoding long repetitive vectors that is defined in package IRanges.<br> The additional argument byStrand governs whether the coverage is computed separately for each strand. If byStrand=FALSE (default) only one result is returned per chromosome. If byStrand=TRUE, there result is two separate Rle objects per chromosome with the strand appended to the chromosome name.<br> By now, the coverage method for AlignedGenomeIntervals makes use of the method for RangedData objects from package IRanges (thanks to a suggestion from P. Aboyoun).
覆盖signature("AlignedGenomeIntervals"):计算只读覆盖了所有的染色体。如果设置正确的organism对象,染色体长度从相应的注释包检索,否则采取的最大间隔结束,是该染色体的绝对长度(股)。参考的结果这个方法是一个列表和个人列表中的元素类Rle,术语重复向量编码的类在包中定义的IRanges参考。额外的参数byStrand执政是否覆盖率分别计算每个链。如果byStrand=FALSE(默认),结果只有一个,每个染色体返回。如果byStrand=TRUE,结果是两个单独的Rle每个染色体的对象附加到染色体名钢绞线。参考现在,coverage使用方法AlignedGenomeIntervals包RangedData(感谢从体育Aboyoun的建议)IRanges对象的方法。




detail signature("AlignedGenomeIntervals"): a more detailed output of all the intervals than provided by show;
详细signature("AlignedGenomeIntervals"):所有比show的间隔更详细的输出;




extend signature("AlignedGenomeIntervals") with additional arguments fiveprime=0L and threeprime=0L. These must be integer numbers and greater than or equal to 0. They specify how much is subtracted from the left border of the interval and added to the right side. Which end is 5' and which one is 3' are determined from the strand information of the object. Lastly, if the object has an organism annotation, it is checked that the right ends of the intervals do not exceed the
延长signature("AlignedGenomeIntervals")额外的参数fiveprime=0L和threeprime=0L。这些都必须是整数,大于或等于0。他们指定左边框的间隔时间减去多少,并添加到右边。这到底是5,其中一个是3的对象链信息确定。最后,如果对象有一个organism注解,它被选中,右两端的间隔不超过




export export the aligned intervals as tab-delimited text files which can be uploaded to the UCSC genome browser as "custom tracks". Currently, there are methods for exporting the data into "bed" format and "bedGraph" format, either writing the intervals from both strands into one file or into two separate files (formats "bedStrand" and "bedGraphStrand", respectively). Details about these track formats can be found at the UCSC genome browser web pages.<br> The additional argument writeHeader can be set to FALSE to suppress writing of the track definition header line to the file.<br> For Genome_intervals objects, only "bed" format is supported at the moment and does not need to be specified.
出口出口对齐制表符分隔的文本文件可以上传UCSC基因组浏览器的“自定义音轨”间隔。目前,出口成“床”的格式和“bedGraph”格式的数据,无论是从两股编写成一个文件的时间间隔或方法分成两个单独的文件(格式“bedStrand和bedGraphStrand”,分别)。这些轨道格式的详情,可参考额外的参数writeHeader可以设置FALSE抑制轨道的定义标题行写入文件。<在UCSC基因组浏览器的网页。 BR>对于Genome_intervals对象,只有床格式支持目前并不需要指定。




hist signature("AlignedGenomeIntervals"): creates
历史signature("AlignedGenomeIntervals"):创建




organism Get or set the organism that the genome intervals in the object correspond to. Should be a predefined code, such as 'Mm' for mouse and 'Hs' for human. The reason for this code, that, if the organism is set, a corresponding annotation package that is called org.<organism>.eg.db is used, for example for obtaining the chromosome lengths to be used in methods such as coverage. These annotation packages can be obtained from the Bioconductor repository.
生物体获取或设置对象的基因组间隔对应的有机体。应该是一个预定义的代码,如鼠标和HS人类MM。此代码的原因,如果设置的有机体,用于相应的注解包,被称为org.<organism>.eg.db,例如取得使用方法,如coverage染色体的长度。这些注解包可以得到来自Bioconductor库。




plot visualisation method; a second argument of class Genome_intervals_stranded can be provided for additional annotation to the plot. Please see below and in the vignette for examples. Refer to the documentation of plotAligned
小区可视化方法;Genome_intervals_stranded类的第二个参数可以提供额外的注释图。请参阅下面的例子中的小插曲。参考的的plotAligned文件




reduce collapse/reduce aligned genome intervals by combining intervals which are completely included in each other, combining overlapping intervals AND combining immediately adjacent intervals (if method="standard"). Intervals are only combined if they are on the same chromosome, the same strand AND have the same match specificity of the aligned reads. <br> If you only want to combine intervals that have exactly the same start and stop position (but may have reads of slightly different sequence aligned to them), then use the argument method="exact". <br> If you only want to combine intervals that have exactly the same 5' or 3' end (but may differ in the other end and in the aligned sequence), then use the argument method="same5" (same 5' end) or method="same3" (same 3' end). <br> Finally, it's possible to only collapse/reduce aligned genome intervals that overlap each other by at least a certain fraction using the argument min.frac. min.frac is a number between 0.0 and 1.0. For example, if you call reduce with argument min.frac=0.4, only intervals that overlap each other by at least 40 percent are collapsed/merged.
减少崩溃/减少相结合,这是完全在对方的时间间隔,结合重叠的时间间隔,并结合立即相邻的时间间隔(如method="standard")相一致的基因组间隔。如果他们是在同一染色体上,同股,有对齐读的同一比赛特异性间隔只有结合。参考,如果您只希望结合有完全相同的启动和停止的位置(但可能已对准他们的略有不同序列读取)的时间间隔,然后使用参数method="exact"。 <br>如果你只是想结合的时间间隔,有相同的5或3端(但在另一端的排列顺序可能有所不同),然后使用参数method="same5"(相同的5端)或method="same3"(相同的3端)。最后,它可能只倍数/降低对齐的基因组至少有一定的分数间隔,重叠使用参数min.frac彼此。 min.frac是0.0和1.0之间的数。例如,如果你打检测reduce参数min.frac=0.4,至少有40%重叠互相间隔是倍数/合并。




sample draw a random sample of n (Argument size) of the aligned reads (without or with replacement) and returns the AlignedGenomeIntervals object defined by
品尝绘制n(参数sizeAlignedGenomeIntervals对象定义)对齐的读取(或不更换),并返回一个随机抽样




score access or set a custom score for the object
得分访问或设置一个自定义的得分为对象




sort sorts the intervals by chromosome name, start and end coordinate in increasing order (unless decreasing=TRUE is
sort排序由染色体名称的时间间隔,开始和结束坐标递增的顺序(除非decreasing=TRUE




subset take a subset of reads, matrix-like subsetting via
子集读取的一个子集,矩阵子集通过


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


Joern Toedling



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

Genome_intervals-class, AlignedRead-class, RangedData-class, RangedData-class, plotAligned
Genome_intervals-class,AlignedRead-class,RangedData-class,RangedData-class,plotAligned


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


  ############# toy example:[############玩具的例子:]
  A <- new("AlignedGenomeIntervals",
         .Data=cbind(c(1,3,4,5,8,10), c(5,5,6,8,9,11)),
         annotation=data.frame(
           seq_name=factor(rep(c("chr1","chr2","chr3"), each=2)),
           strand=factor(c("-","-","+","+","+","+") ,levels=c("-","+")),
           inter_base=rep(FALSE, 6)),
         reads=rep(3L, 6), matches=rep(1L,6),
         sequence=c("ACATT","ACA","CGT","GTAA","AG","CT"))

  show(A)
  detail(A)

  ## alternative initiation of this object:[#此对象的替代启动:]
  A <- AlignedGenomeIntervals(
     start=c(1,3,4,5,8,10), end=c(5,5,6,8,9,11),
     chromosome=rep(c("chr2","chrX","chr1"), each=2),
     strand=c("-","-","+","+","+","+"),
     sequence=c("ACATT","ACA","CGT","GGAA","AG","CT"),
     reads=c(1L, 5L, 2L, 7L, 3L, 3L))
  detail(A)

  ## custom identifiers can be assigned to the intervals[#自定义的标识符可以分配到的时间间隔]
  id(A) <- paste("gi", 1:6, sep="")

  ## subsetting and combining[#子集,并结合]
  detail(A[c(1:4)])
  detail(c(A[1], A[4]))

  ## sorting: always useful[#排序:总是有用]
  A <- sort(A)
  detail(A)
  
  ## the 'reduce' method provides a cleaned-up, compact set[#“减少”的方法,提供清洁,紧集]
  detail(reduce(A))
  ##  with arguments specifying additional conditions for merging[#参数指定合并的附加条件]
  detail(reduce(A, min.frac=0.8))

  ## 'sample' to draw a sample subset of reads and their intervals[#“样品”画一个读取和间隔的样本子集]
  detail(sample(A, 10))
  
  ## biological example[#生物的例子]
  exDir <- system.file("extdata", package="girafe")
  exA   <- readAligned(dirPath=exDir, type="Bowtie",
    pattern="aravinSRNA_23_no_adapter_excerpt_mm9_unmasked.bwtmap")
  exAI <- as(exA, "AlignedGenomeIntervals")
  organism(exAI) <- "Mm"
  show(exAI)
  ## which chromosomes are the intervals on?[#染色体上间隔?]
  table(chromosome(exAI))

  ## subset[#子集]
  exAI[is.element(chromosome(exAI),  c("chr1","chr2"))]

  ## compute coverage per chromosome:[#计算每个染色体的报道:]
  coverage(exAI[is.element(chromosome(exAI),  c("chr1","chr2"))])

  ### plotting:[##绘制:]
  load(file.path(exDir, "mgi_gi.RData"))
  plot(exAI, mgi.gi, chr="chrX", start=50400000, end=50410000)

  ### overlap with annotated genome elements:[#重叠带注释的基因组元素:]
  exOv <- interval_overlap(exAI, mgi.gi)
  ## how many elements do read match positions generally overlap:[#多少个元素不读比赛职位一般重叠:]
  table(listLen(exOv))
  ## what are the 13 elements overlapped by a single match position:[#什么是由一个单一的比赛位置重叠的13个元素:]
  mgi.gi[exOv[[which.max(listLen(exOv))]]]
  ## what kinds of elements are overlapped[#种元素重叠]
  (tabOv <- table(as.character(mgi.gi$type)[unlist(exOv)]))
  ### display those classes:[#显示这些类:]
  my.cols <- rainbow(length(tabOv))
  pie(tabOv, col=my.cols, radius=0.85)

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


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

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-2-7 01:55 , Processed in 0.037954 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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