Skip to main content

Crate use_genomic_range

Crate use_genomic_range 

Source
Expand description

§use-genomic-range

Primitive genomic range and interval vocabulary.

use-genomic-range stores start and end positions, strand labels, and coordinate-system labels. It validates that the end is not before the start. It does not parse BED/GFF/GTF/SAM/BAM, implement interval trees, or behave as a genome browser.

use use_genomic_range::{CoordinateSystem, GenomicPosition, GenomicRange, Strand};

let range = GenomicRange::new(GenomicPosition::new(10), GenomicPosition::new(20))
    .unwrap()
    .with_coordinate_system(CoordinateSystem::ZeroBasedHalfOpen)
    .with_strand(Strand::Forward);

assert_eq!(range.len(), 10);
assert_eq!(range.strand(), &Strand::Forward);

Structs§

GenomicPosition
A genomic position value.
GenomicRange
A genomic interval with explicit coordinate assumptions.

Enums§

CoordinateSystem
Coordinate-system vocabulary for genomic ranges.
GenomicRangeError
Error returned by genomic range constructors.
Strand
Strand orientation vocabulary.