+ found bug which caused ~10 reads of overlap "0"
[qpalma.git] / tools / data_tools / PyGff.py
1 #!/usr/bin/env python
2 # -*- coding: utf-8 -*-
3
4 class Gene:
5
6 def __init__(self,chr,begin,end,strand):
7 assert chr != ''
8 assert begin >= 0 and begin <= end and end >= 0
9 assert strand in ['+','-']
10
11 self.chromosome = chr
12 self.start = begin
13 self.stop = end
14 self.strand = strand
15 self.exons = []
16 self.fiveUTR = []
17 self.threeUTR = []
18
19 def addExon(self,start,stop):
20 self.exons.append((start,stop))
21
22 def load(self,filename):
23 pass
24
25 def save(self,filename):
26 pass