added on minimum intertime for thresholding