allow the number of samples to be specified on the command line