Skip to content

Commit

Permalink
Per #1761, add warning for percentiles > 100.
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnHalleyGotway committed Oct 27, 2021
1 parent 9a156b3 commit d390942
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion met/src/basic/vx_config/threshold.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1139,7 +1139,14 @@ else {
else if ( op == thresh_ge || op == thresh_gt ) PT_new = PT * fbias_val;
}

if ( PT_new > 100.0 ) PT_new = 100.0;
if ( PT_new > 100.0 ) {
mlog << Warning << "\nSimple_Node::set_perc() -> "
<< "For " << (fbias_fcst ? "forecast" : "observation" )
<< " threshold \"" << s << "\" the required percentile of "
<< PT_new << " exceeds the maximum possible value. "
<< "Resetting to 100.\n\n";
PT_new = 100.0;
}

mlog << Debug(3)
<< "For " << (fbias_fcst ? "forecast" : "observation" )
Expand Down

0 comments on commit d390942

Please sign in to comment.