Previous changeset 1:2f7278120be9 (2016-03-22) Next changeset 3:36388b666bfc (2016-11-09) |
Commit message:
planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/msp_fasta_tabular_converter commit 030207144f0811822dbdda9a10e036ff8e794d7c |
modified:
fasta_tabular_converter.py |
b |
diff -r 2f7278120be9 -r 330dd8a8c31a fasta_tabular_converter.py --- a/fasta_tabular_converter.py Tue Mar 22 18:54:00 2016 -0400 +++ b/fasta_tabular_converter.py Fri Mar 25 19:29:40 2016 -0400 |
[ |
@@ -26,7 +26,9 @@ stringlist=[] else: stringlist.append(line[:-1]) - seqdic["".join(stringlist)] += 1 # for the last sequence + try: + seqdic["".join(stringlist)] += 1 # for the last sequence + except: pass # in case file to convert is empty F.close() F = open(tabular, "w") for seq in sorted(seqdic, key=seqdic.get, reverse=True): @@ -105,4 +107,4 @@ if __name__ == "__main__": seqdic = defaultdict(int) args = Parser() - main (args.input, args.output, args.type) \ No newline at end of file + main (args.input, args.output, args.type) |