Commit b95872fd authored by Penom Nom's avatar Penom Nom
Browse files

Move cigarlineGraph right version.

parent 4dce7047
......@@ -314,10 +314,10 @@ if __name__ == '__main__':
parser = argparse.ArgumentParser(
description="description : Sum by position the status of reads. This provides for example the number of reads that have a mismatch at first base.",
usage='samtools view INPUT_BAM_FILE | %(prog)s - --output OUTPUT_FILE [--output OUTPUT_FILE_R2 --readsplit]')
usage='samtools view INPUT_BAM_FILE | %(prog)s -i - -o OUTPUT_FILE [OUTPUT_FILE_R2 --readsplit]')
parser.add_argument("input", type=argparse.FileType('r'), help="The SAM file")
parser.add_argument("--output", action='append', type=argparse.FileType('w'), help="The file(s) with count.")
parser.add_argument("-i", "--input", type=argparse.FileType('r'), default=sys.stdin, help="The SAM file")
parser.add_argument("-o", "--output", nargs='*', type=argparse.FileType('w'), required=True, help="The file(s) with count.")
parser.add_argument("--readsplit", action="store_true", help="if specified, reads statstics are splitted in two outputs (reads 1 and reads 2).")
parser.add_argument("--separator", dest="separator", default="\t", help="The fields separator in output file(s) (default : tabulation).")
parser.add_argument("--version", action='version', version=__version__)
......@@ -335,7 +335,7 @@ if __name__ == '__main__':
#Sum by position the status of reads
sumStatus( args.input, nb_by_pos )
print args.output
#Write output
if len(args.output)==2 :
writeOutput( args.output[0], args.separator, nb_by_pos["read1"] )
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment