Skip to content

Repository files navigation

waterNETN

This package contains functions that import database views from the water data package Access database and/or CSVs in the NETN water data package and provides functions to query, summarize, and visualize NETN water data. The R package can be installed using pak::pkg_install('doi-nps/waterNETN'). Previous archived versions of this R package can be found at www.github.com/katemmiller/waterNETN

This package includes the following functions:

  • importData: Import views from data package MS Access database or as a zip file of csvs.
  • exportData: Export views as CSVs to prepare for data package.
  • prepFMtoAccess: preps water data exported from the FileMaker app for import into the MS Access backend database. Note: Not sure if this function is fully functional (depends on whether database is set up to import a CSV).

  • getSites: queries location information common across lakes and streams.
  • getSitesLake: queries location information specific to lakes.
  • getSitesStream: queries location information specific to streams.
  • getEvents: queries visit-level data for NETN water monitoring.

  • getChemistry: queries NETN water chemistry data that were measured in the lab.
  • getDischarge: queries NETN water discharge data for stream sites.
  • getLightPen: queries light penetration data for lake monitoring.
  • getSecchi: queries Secchi depth data for lake monitoring.
  • getSondeInSitu: queries water data collected with by a Sonde in the field.
  • getStreamObs: queries stream observation data.
  • getWaterLevel: queries water level data.
  • plotLakeProfile: plots metrics collected in lake profiles.
  • plotPrecipDischarge: plots precipitation vs. stream discharge. The package doi-nps/climateNETN must be installed for this function.
  • plotScatterPlot: plots a scatterplot of 2 water quality or quantity metrics.
  • plotTrend: plots a water metric over time and includes option to add loess smoother.
  • plotWaterBands: plots current year of water in comparison to the distribution of water data collected in specified previous years.

  • sumEvents: Summarize the number of samples collected at each site by year, month, parameter, and whether measurement was real or censored.
  • theme_WQ: custom ggplot2 theme for plotting NETN water data.

The docs/ folder includes multiple files that are useful for automated reporting and the tutorial website:

  • index.Rmd and its output index.html are the files that generate the waterNETN tutorial website.
  • QC_NETN_report.RMD performs automated QC checks on the data. Note that the WC_NETN_compile.R and QC_NETN_report_functions.R are sourced in the RMD.
  • header_manual.html generates th NPS banner for both RMD headers.
  • www/ folder contains the css and images sourced in the RMDs.

About

R package for importing, joining, and querying Northeast Temperate Network water data

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages