Skip to contents

Calculate non-point source (NPS) loads for Tampa Bay

Usage

anlz_nps(
  yrrng = c("2021-01-01", "2023-12-31"),
  tbbase,
  rain,
  mancopth,
  pincopth,
  lakemanpth,
  tampabypth,
  bellshlpth,
  vernafl,
  verbose = T
)

Arguments

yrrng

A vector of two dates in 'YYYY-MM-DD' format, specifying the date range to retrieve flow data. Default is from '2021-01-01' to '2023-12-31'.

tbbase

data frame containing polygon areas for the combined data layer of bay segment, basin, jurisdiction, land use data, and soils, see details

rain

data frame of rainfall data, see details

mancopth

character, path to the Manatee County water quality data file, see details

pincopth

character, path to the Pinellas County water quality data file, see details

lakemanpth

character, path to the file containing the Lake Manatee flow data, see details

tampabypth

character, path to the file containing the Tampa Bypass flow data, see details

bellshlpth

character, path to the file containing the Bell shoals data, see details

vernafl

character vector of file path to Verna Wellfield atmospheric concentration data

verbose

logical indicating whether to print verbose output

Value

A data frame of non-point source loads for Tampa Bay, including columns for year, month, basin, bay segment, basin area (hectares), and loads for water, total nitrogen (TN), total phosphorus (TP), total suspended solids (TSS), and biochemical oxygen demand (BOD).

Details

The function estimates non-point source (NPS) loads for Tampa Bay by combining ungaged and gaged NPS loads. Ungaged loads are estimated using rainfall, flow, event mean concentration, land use, and soils data, while gaged loads are estimated using water quality data and flow data. The function also incorporates atmospheric concentration data from the Verna Wellfield site.

The following functions are used internally and are provided here for reference on the components used in the calculations:

Examples

if (FALSE) { # \dontrun{
data(tbbase)
data(rain)
mancopth <- system.file('extdata/nps_wq_manco.txt', package = 'tbeploads')
pincopth <- system.file('extdata/nps_wq_pinco.txt', package = 'tbeploads')
lakemanpth <- system.file('extdata/nps_extflow_lakemanatee.xlsx', package = 'tbeploads')
tampabypth <- system.file('extdata/nps_extflow_tampabypass.xlsx', package = 'tbeploads')
bellshlpth <- system.file('extdata/nps_extflow_bellshoals.xls', package = 'tbeploads')
vernafl <- system.file('extdata/verna-raw.csv', package = 'tbeploads')

anlz_nps(yrrng = c('2021-01-01', '2023-12-31'), tbbase, rain, mancopth, pincopth,
         lakemanpth, tampabypth, bellshlpth, vernafl, verbose = TRUE)
} # }