【问题标题】:genomic coordinate in RR中的基因组坐标
【发布时间】:2021-06-12 02:58:28
【问题描述】:

我正在处理TxDb.Hsapiens.UCSC.hg19.knownGene 数据。我发现最大外显子的长度是 205012。如何继续找到该外显子的基因组坐标?

【问题讨论】:

  • 欢迎来到stackoverflow。到目前为止,您尝试过什么?
  • 如果您使用函数max 找到了最大范围,您可能需要考虑使用函数which.max 来知道哪个是最大值。

标签: r bioinformatics genomicranges iranges


【解决方案1】:

您可以在 Granges 上使用 which.max(),如下所示:

library(TxDb.Hsapiens.UCSC.hg19.knownGene)
txdb = TxDb.Hsapiens.UCSC.hg19.knownGene
ex = exons(txdb)
ex$len = width(ex)
ex[which.max(ex$len)]

GRanges object with 1 range and 2 metadata columns:
      seqnames              ranges strand |   exon_id       len
         <Rle>           <IRanges>  <Rle> | <integer> <integer>
  [1]    chr12 102591363-102796374      + |    164764    205012
  -------
  seqinfo: 93 sequences (1 circular) from hg19 genome

【讨论】:

猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2013-12-13
  • 1970-01-01
  • 2019-06-28
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多