checkMWRwqx {MassWateR}R Documentation

Check water quality exchange (wqx) metadata input

Description

Check water quality exchange (wqx) metadata input

Usage

checkMWRwqx(wqxdat, warn = TRUE)

Arguments

wqxdat

input data frame

warn

logical to return warnings to the console (default)

Details

This function is used internally within readMWRwqx to run several checks on the input data for conformance with downstream functions

The following checks are made:

Value

wqxdat is returned as is if no errors are found, otherwise an informative error message is returned prompting the user to make the required correction to the raw data before proceeding. Checks with warnings can be fixed at the discretion of the user before proceeding.

Examples

library(dplyr)

wqxpth <- system.file('extdata/ExampleWQX.xlsx', package = 'MassWateR')

wqxdat <- readxl::read_excel(wqxpth, na = c('NA', 'na', ''), col_types = 'text')
    
checkMWRwqx(wqxdat)

[Package MassWateR version 2.1.4 Index]