06/04/14 ai added code to write out a txt file that reports number of trials per task.