Closed slevin75 closed 1 year ago
OK, I have updated the find_events_mod function and reran the p2 targets. I think everything is functioning correctly now.
@jds485 actually - wait don't re-review it yet. I think I messed up one thing. I'm not sure I left in the option to keep overlapping quantiles now.
I haven't updated the calcHIT function yet, but in the interest of getting these changes through, I am putting in this pr.
In this PR, I created find_events_mod function which is the find_events function from EflowStats modified to accept a lower and upper threshold. The thresholds will be set within in the calcFDC function. For 'high' threshold types, events are defined as: (discharge > threshold_lower) & (discharge <= discharge_upper)
Within the cal_FDC function, if allow_event_overlap = FALSE , lower thresholds are set from the vector of NE_flows. This will prevent overlapping events in aggregated groups. If allow_event_overlap = TRUE, lower threshold stays the same and upper threshold will be max(discharge) for all NE_flows and this will revert back to the original event definition. For 'low' threshold types, events are defined as: (discharge < threshold_upper + 0.001) & (discharge >= discharge_lower) 0.001 implemented previously in order to get discharge <= threshold_upper for the low threshold type.
Results shown for an example gage. These plots aren't in the pr, I just coded them up to look at the results really quickly, but I can add them if you want.
Closes #137