Add error tracking to thresholding methods