added iterations option