Added iterations parameter to run.