view parse_aln.py @ 14:a6c55d1bdb6c draft

Uploaded
author petr-novak
date Wed, 28 Aug 2019 08:08:47 -0400
parents
children 3151a72a6671
line wrap: on
line source

#!/usr/bin/env python3
'''
parse .aln file - output from cap3 program. Output is fasta file and
profile file
'''
import argparse


def parse_args():
    '''Argument parsin'''
    description = """
    parsing cap3 assembly aln output
    """
    parser = argparse.ArgumentParser(description=description,
                                     formatter_class=argparse.RawTextHelpFormatter)
    parser.add_argument(
        '-a', '--aln_file',
        default=None, required=True,
        help="Aln file input",
        type=str,
        action='store')
    parser.add_argument(
        '-f', '--fasta',
        default=None, required=True,
        help="fasta output file name",
        type=str,
        action='store')
    parser.add_argument(
        '-p', '--profile',
        default=None, required=True,
        help="output file for coverage profile",
        type=str,
        action="store"
    )
    return parser.parse_args()


if __name__ == "__main__":

    args = parse_args()
    print(args.profile)