def parse_catalytic(insertion, gff):
offset = insertion['<STR_LIT>']<EOL>GeneStrand = insertion['<STR_LIT>']<EOL>if type(insertion['<STR_LIT>']) is not str:<EOL><INDENT>return gff<EOL><DEDENT>for intron in parse_fasta(insertion['<STR_LIT>'].split('<STR_LIT:|>')):<EOL><INDENT>ID, annot, strand, pos = intron[<NUM_LIT:0>].split('<STR_LIT:>>')[<NUM_LIT:1>].split()<EOL>Start, End = [int(i) for i in pos.split('<STR_LIT:->')]<EOL>if strand != GeneStrand:<EOL><INDENT>if strand == '<STR_LIT:+>':<EOL><INDENT>strand = '<STR_LIT:->'<EOL><DEDENT>else:<EOL><INDENT>strand = '<STR_LIT:+>'<EOL><DEDENT>Start, End = End - <NUM_LIT:2>, Start - <NUM_LIT:2><EOL><DEDENT>Start, End = abs(Start + offset) - <NUM_LIT:1>, abs(End + offset) - <NUM_LIT:1><EOL>gff['<STR_LIT>'].append(insertion['<STR_LIT>'])<EOL>gff['<STR_LIT:source>'].append('<STR_LIT>')<EOL>gff['<STR_LIT>'].append('<STR_LIT>')<EOL>gff['<STR_LIT:start>'].append(Start)<EOL>gff['<STR_LIT:end>'].append(End)<EOL>gff['<STR_LIT>'].append('<STR_LIT:.>')<EOL>gff['<STR_LIT>'].append(strand)<EOL>gff['<STR_LIT>'].append('<STR_LIT:.>')<EOL>gff['<STR_LIT>'].append('<STR_LIT>' % (ID, annot))<EOL><DEDENT>return gff<EOL>
parse catalytic RNAs to gff format