Add in ability to set a temporary directory

Add in a new option to many of the subcommands to set the directory for temporary files. I didn't know which subcommands actually used temporary files so I added the option to all of them minus the plot generating ones. I implemented it as a custom action for the option parser so that I didn't need to modify too much of the code. These changes fixed issue #9