Fixing threshold; should be double, not int