correcting spelling of noiseThreshold so noiseThreshold ternary operator works