added function defaults to parameters so this can be scheduled