MinThreshold added with tests