use correct dt and threshold