Class Genes

java.lang.Object
org.snpeff.interval.Genes
All Implemented Interfaces:
Serializable, Iterable<Gene>

public class Genes extends Object implements Iterable<Gene>, Serializable
A collection of genes (marker intervals) Note: It is assumed that all genes belong to the same genome
Author:
pcingola
See Also:
  • Field Details

    • debug

      public boolean debug
  • Constructor Details

    • Genes

      public Genes(Genome genome)
  • Method Details

    • add

      public void add(Gene gene)
      Add a gene interval to this collection
    • createCircularGenes

      public void createCircularGenes()
      In a circular genome, a gene can have negative coordinates or crosses over chromosome end. These genes are mirrored to the opposite end of the chromosome so that they can be referenced by both circular coordinates.
    • createIntergenic

      public List<Intergenic> createIntergenic()
      Creates a list of Intergenic regions
    • createSpliceSites

      public void createSpliceSites(int spliceSiteSize, int spliceRegionExonSize, int spliceRegionIntronMin, int spliceRegionIntronMax)
      Create splice sites.
      Parameters:
      createIfMissing - : If true, create canonical splice sites if they are missing. For a definition of splice site, see comments at the beginning of SpliceSite.java
    • createUpDownStream

      public List<Marker> createUpDownStream(int upDownLength)
      Creates a list of UP/DOWN stream regions (for each transcript) Upstream (downstream) stream is defined as upDownLength before (after) transcript Note: If upDownLength invalid input: '<'=0 no interval is created
    • findTranscript

      public Transcript findTranscript(String trId)
      Find a transcript by ID
    • get

      public Gene get(String geneId)
      Obtain a gene interval
    • getGeneByName

      public Gene getGeneByName(String geneName)
      Obtain a gene by GeneName WARNING: The first match is returned. If multiple genes share the same gene name, no order can be expected for this method.
    • iterator

      public Iterator<Gene> iterator()
      Specified by:
      iterator in interface Iterable<Gene>
    • size

      public int size()
    • sorted

      public Collection<Gene> sorted()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • values

      public Collection<Gene> values()