prepWQPData: Prep WQP Data

View source: R/prepWQPData.R

prepWQPDataR Documentation

Prep WQP Data

Description

This function reads dataframes downloaded from EPA's WQP, removes duplicates, and converts result values and detection limit values with non-numeric characters to NA (with the exception of those with <|>|,). Converts all non-result value columns in nr, activity, detquantlim, and sites objects to character, including dates. Replaces hard coding in bookdown and readWQPFiles function.

Usage

prepWQPData(irdata, char_check = TRUE)

Arguments

irdata

A list of WQP dataframes containing sites, narrowresult, activity, and detquantlim objects.

char_check

Logical. If TRUE, the function produces a .csv showing all the special characters changed or converted to NA.

Value

A list consisting of nr, activity, detquantlim, sites, filtered sites, and merged_results (nr combined with activity) dataframes with special characters converted to NA for the ResultMeasureValue column. Saves an rdata file named "irdata_prepped.Rdata" containing the six data WQP objects.


ut-ir-tools/irTools documentation built on Jan. 19, 2024, 6:55 p.m.