from cogent3 import load_seq
seq = load_seq("data/C-elegans-chromosome-I.gb", moltype="dna")
seq| 0 | |
| I | GCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAA |
DnaSequence, length=15,072,434 (truncated to 60)
A sequence “feature” is an annotated segment, with the annotations being generated either computationally, e.g. repeat classification, or experimentally, e.g. single nucleotide polymorphism. In this example, we just load both sequence and features from a GenBank record.
We load chromosome I of Caenorhabditis elegans.
| 0 | |
| I | GCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAAGCCTAA |
DnaSequence, length=15,072,434 (truncated to 60)
As you can see it’s quite large. It doesn’t make sense to try and display all the features, so we will slice it down to a 10kbp segment.
Drawing features is then limited to features within that segment.
If a feature extends outside the displayed segment, it’s hover text indicates it as “(incomplete)”.
We specify what biotypes we want to display.