diff --git a/scripts/load-into-counting.py b/scripts/load-into-counting.py index e7323ddc2a..cef2716223 100755 --- a/scripts/load-into-counting.py +++ b/scripts/load-into-counting.py @@ -56,8 +56,8 @@ def get_parser(): parser.add_argument('-b', '--no-bigcount', dest='bigcount', default=True, action='store_false', help='Do not count k-mers past 255') - parser.add_argument('--machine-readable-info', '-m', default=None, - metavar="FORMAT", choices=['json', 'tsv'], + parser.add_argument('--summary-info', '-s', default=None, metavar="FORMAT", + choices=['json', 'tsv'], help="What format should the machine readable run " "summary be in? (json or tsv, disabled by default)") parser.add_argument('--report-total-kmers', '-t', action='store_true', @@ -137,10 +137,10 @@ def main(): print >> sys.stderr, "Writing run information to", base + '.info' print >> info_fp, 'fp rate estimated to be %1.3f\n' % fp_rate - if args.machine_readable_info: - mr_fmt = args.machine_readable_info.lower() + if args.summary_info: + mr_fmt = args.summary_info.lower() mr_file = base + '.info.' + mr_fmt - print >> sys.stderr, "Writing machine-readable stats to", mr_file + print >> sys.stderr, "Writing summmary info to", mr_file with open(mr_file, 'w') as mr_fh: if mr_fmt == 'json': mr_data = { diff --git a/tests/test_scripts.py b/tests/test_scripts.py index 8d20aab45b..8d6b3627e9 100644 --- a/tests/test_scripts.py +++ b/tests/test_scripts.py @@ -69,7 +69,7 @@ def test_load_into_counting_fail(): def test_load_into_counting_tsv(): script = scriptpath('load-into-counting.py') - args = ['-x', '1e7', '-N', '2', '-k', '20', '-t', '-m', 'tsv'] + args = ['-x', '1e7', '-N', '2', '-k', '20', '-t', '-s', 'tsv'] outfile = utils.get_temp_filename('out.kh') tabfile = outfile + '.info.tsv' @@ -91,7 +91,7 @@ def test_load_into_counting_tsv(): def test_load_into_counting_json(): script = scriptpath('load-into-counting.py') - args = ['-x', '1e7', '-N', '2', '-k', '20', '-t', '-m', 'json'] + args = ['-x', '1e7', '-N', '2', '-k', '20', '-t', '-s', 'json'] outfile = utils.get_temp_filename('out.kh') jsonfile = outfile + '.info.json' @@ -118,9 +118,9 @@ def test_load_into_counting_json(): assert got_json == expected_json, got_json -def test_load_into_counting_bad_machine_readable_fmt(): +def test_load_into_counting_bad_summary_fmt(): script = scriptpath('load-into-counting.py') - args = ['-x', '1e7', '-N', '2', '-k', '20', '-m', 'badfmt'] + args = ['-x', '1e7', '-N', '2', '-k', '20', '-s', 'badfmt'] outfile = utils.get_temp_filename('out.kh') infile = utils.get_test_data('test-abund-read-2.fa')