Better threshold estimation