Mercurial > repos > iuc > jbrowse
diff blastxml_to_gapped_gff3.py @ 42:c1451868f8d4 draft
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/jbrowse commit 0bfb0de98c918860c21808e8832caad9f0535975
| author | iuc |
|---|---|
| date | Thu, 08 Jun 2017 17:31:17 -0400 |
| parents | d5e8d72c432a |
| children | 665c4f3e48ae |
line wrap: on
line diff
--- a/blastxml_to_gapped_gff3.py Wed Mar 01 23:50:09 2017 -0500 +++ b/blastxml_to_gapped_gff3.py Thu Jun 08 17:31:17 2017 -0400 @@ -1,10 +1,12 @@ -#!/usr/bin/perl +#!/usr/bin/env python +import argparse +import copy +import logging import re import sys -import copy -import argparse + from BCBio import GFF -import logging + logging.basicConfig(level=logging.INFO) log = logging.getLogger(name='blastxml2gff3') @@ -218,7 +220,6 @@ else: log.warn("Bad data: \n\t%s\n\t%s\n\t%s\n" % (query, match, subject)) - if strict_m: if ret == '=' or ret == 'X': ret = 'M' @@ -252,7 +253,7 @@ if __name__ == '__main__': parser = argparse.ArgumentParser(description='Convert Blast XML to gapped GFF3', epilog='') - parser.add_argument('blastxml', type=file, help='Blast XML Output') + parser.add_argument('blastxml', type=open, help='Blast XML Output') parser.add_argument('--min_gap', type=int, help='Maximum gap size before generating a new match_part', default=3) parser.add_argument('--trim', action='store_true', help='Trim blast hits to be only as long as the parent feature') parser.add_argument('--trim_end', action='store_true', help='Cut blast results off at end of gene')
