simulation.stats: Simulation Stats

simulation.statsR Documentation

Simulation Stats

Description

Summarize and Evaluate System Performance

Usage

marsOvertoppingCheck_bool(waterlevel_ft, storage_depth_ft)

marsPeakStorage_percent(waterlevel_ft, storage_depth_ft)

marsPeakReleaseRate_cfs(dtime_est, orifice_outflow_ft3)

marsDraindown_hr(dtime_est, rainfall_in, waterlevel_ft)

Arguments

waterlevel_ft

Water Level (ft)

storage_depth_ft

Total storage Depth (ft)

dtime_est

A vector of POSIXct date times, in ascending order

orifice_outflow_ft3

Orifice outflow volume (cf)

rainfall_in

Rainfall depths during periods corresponding to times in dtime_est (in)

Value

marsOvertoppingCheck_bool

Output is TRUE or FALSE based on overtopping evaluation

-710

No Water Level were provided for evaluation

-720

Non-numeric argument was provided for either storage_depth_ft

marsPeakStorage_percent

Output is a percentage of peak storage filled, by depth

marsPeakReleaseRate_cfs

Output is peak orifice release rate (cfs)

marsDraindown_hr

Output is Calculated Draindown time (hr). Returns NA if water level does not return to the starting level after event.

marsDraindown_hr

Output is Calculated Draindown time (hr).Returns the following outputs as coders for these error messages:

-810

Water level does not respond to rain event

-820

Water level does not return to a stable baseline

-830

There is an increase during the descending limb that pushes the draindown time more than one hour

-840

Water level did not drop below baseline

Examples


simulation_summary <- simulated_data %>%
  dplyr::group_by(event) %>%
  dplyr::summarize(startdate = min(dtime_est), #add start date of event to summary table,
                  
   #1. Overtopping check
   overtopping = marsOvertoppingCheck_bool(Simulated_depth_ft,smp_stats$storage_depth_ft[7]),

   #2. Simulated storage utilization
   peakUtilization = marsPeakStorage_percent(Simulated_depth_ft,smp_stats$storage_depth_ft[7]),

   #3. Peak release rate
   peakReleaseRate_cfs = marsPeakReleaseRate_cfs(dtime_est, Simulated_orifice_vol_ft3),

   #4. Total orifice outflow volume (rounded for table format)
   orifice_volume_ft3 = round(sum(Simulated_orifice_vol_ft3),0),

   #5. Draindown time
   draindown_time_hr = marsDraindown_hr(dtime_est, rainfall_in, Simulated_depth_ft))
   

taywater/pwdgsi documentation built on Aug. 21, 2024, 4:31 p.m.