Search results and annotations are a linear sequence along an undefined path. A few times now I've found myself wanting to do something like:
match = bg.search('foo')[0]
if match.strand = '-':
print( bg[match.end()-1 : match.start()] )
that basic integer math won't work across junctions, but in many cases you don't have a junction right there, so we should support it. I've also got an idea on how to handle junctions well (fanning out into a subgraph), but need to think about it more.
Search results and annotations are a linear sequence along an undefined path. A few times now I've found myself wanting to do something like:
match = bg.search('foo')[0]
if match.strand = '-':
print( bg[match.end()-1 : match.start()] )
that basic integer math won't work across junctions, but in many cases you don't have a junction right there, so we should support it. I've also got an idea on how to handle junctions well (fanning out into a subgraph), but need to think about it more.