I wrote a Python script that I am now trying to get to run via the command line. It consists of a function that takes one obligatory and a few optional arguments.
def main(input_folder, iterations = 1000, probability_cutoff = - 40 , threshold = 10): ...
if __name__ == "__main__":
I always use argparse, because it gives you nice error handling and clearly documents the options. However, this should do what you want:
if __name__ == "__main__": main(*sys.argv[1:])