Thresholding added