Added high alert threshold function