Skip to content
Snippets Groups Projects
Commit 56b772a0 authored by marc's avatar marc
Browse files

Added command line argument functionality

parent 9a48169e
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env python
import sys
def calc_gc_perc(seq):
atc,gcc = 0, 0
......@@ -9,5 +10,6 @@ def calc_gc_perc(seq):
gcc += 1
return gcc * 100 / (gcc + atc)
print "the sequence is 'CAGG', and has a GC% of {:.2f}".format( calc_gc_perc('CAGG') )
inpseq = sys.argv[1]
print "the sequence is 'CAGG', and has a GC% of {:.2f}".format( calc_gc_perc(inpseq) )
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment