Fix to badly-formatted tree and random number seed

Fixes issue #3 (badly-formatted tree).
Also adds an option to specify a random number seed for reproducibility. In doing this, I've also turned off multiple initializations of srand which is only required once.

HTH.