added support for running multiple iterations