Correction of density calculations after threshold was changed