Learn R Programming

wq (version 0.4.8)

wq-package: \Sexpr[results=rd,stage=build]{tools:::Rd_package_title("#1")}wqExploring Water Quality Monitoring Data

Description

\Sexpr[results=rd,stage=build]{tools:::Rd_package_description("#1")}wqFunctions to assist in the processing and exploration of data from environmental monitoring programs. The package name stands for "water quality" and reflects the original focus on time series data for physical and chemical properties of water, as well as the biota. Intended for programs that sample approximately monthly, quarterly or annually at discrete stations, a feature of many legacy data sets. Most of the functions should be useful for analysis of similar-frequency time series regardless of the subject matter.

Arguments

Details

The main purpose of wq is to explore seasonal time series through plots and nonparametric trend tests. It was created originally to examine water quality data sets (hence, “wq”) but is suitable as a more general purpose set of tools for looking at annual or seasonal time series.

One of the more tedious tasks in exploring environmental data sets is creating usable time series from the original complex data sets, especially when you want many series at will that group data in different ways. So wq also provides a way of transforming data sets to a common format that then allows a diversity of time series to be created quickly. A few functions are specific to the fields of limnology and oceanography.

The plots are designed for easy use, not for publication-quality graphs. Nonetheless, extensive customization is possible by passing options through ..., adding annotations in the case of base graphics, and adding layers in the case of ggplot2 objects.

Two functions are used mainly for preparing the times series:

  • a function that transforms incoming data to a common data structure in the form of the WqData class
  • a function that easily prepares time series objects from this class

The WqData class can be easily adapted to non-aquatic data. Obviously, the depth field can be used for elevation in atmospheric studies. But more generally, the site and depth fields can be used for many two-way classifications and don't need to refer to spatial location.

Some of the time series functions include:

  • a variety of plots to examine changes in seasonal patterns
  • nonparametric trend tests
  • time series interpolation and related manipulations
  • a simple decomposition of a series into different time scales
  • phenological analyses
  • the use of empirical orthogonal functions to detect multiple independent mechanisms underlying temporal change

A few functions are specialized for the aquatic sciences:

  • converting between oxygen concentrations and percent saturation
  • converting between salinity and conductivity

The capabilities of wq are more fully explained in the accompanying vignette: “wq: Exploring environmental monitoring data”.