You should have Python and the required modules installed.
First, if you have Git installed, clone the Git repository:
$ git clone https://github.com/phyletica/SumTimes.git
If you do not have Git, you can download a snapshot of the repository as a tar or zip archive by clicking the respective folder icons at the top of this page. Either way, move into the downloaded directory:
$ cd SumTimes
Next, let’s make sure SumTimes is working as expected on your machine:
$ ./sumtimes.py --run-tests
This will run a suite of tests. All of SumTimes is self-contained within the sumtimes.py script, so to install, all you need to do is copy (or link) the sumtimes.py file to a location that is in your PATH. For example:
$ sudo cp sumtimes.py /usr/local/bin
Or:
$ cp sumtimes.py ~/bin
Alternatively, you can run sumtimes.py from your current directory by using the ./|st| like we did above when we ran the tests. However, the remainder of this documentation assumes the script is in your PATH, so if it is not, you will have to remember to add the “./” bit.
You should be able to call up the help menu of sumtimes.py:
$ ./sumtimes.py -h
You should see output that looks like:
usage: sumtimes.py [-h] [--np NP] [--seed SEED] YAML-CONFIG-PATH
sumtimes.py Version 0.1.0
positional arguments:
YAML-CONFIG-PATH Path to the YAML-formatted config file.
optional arguments:
-h, --help show this help message and exit
--np NP The maximum number of processes to run in parallel. The
default is the smaller of the number of tree files or the
number of CPUs available on the machine.
--seed SEED Random number seed to use for the analysis.