Compare-censored: Comparison Methods for 'lcens', 'mcens', and 'qw' objects

Compare-censoredR Documentation

Comparison Methods for lcens, mcens, and qw objects

Description

Comprisons are possible and well-defined between numeric and censored or water-quality data. Comparisons between censored data types are not supported in this version.

Usage

## S4 method for signature 'lcens,numeric'
Compare(e1, e2)

## S4 method for signature 'mcens,numeric'
Compare(e1, e2)

## S4 method for signature 'qw,numeric'
Compare(e1, e2)

## S4 method for signature 'numeric,lcens'
Compare(e1, e2)

## S4 method for signature 'numeric,mcens'
Compare(e1, e2)

## S4 method for signature 'numeric,qw'
Compare(e1, e2)

Arguments

e1, e2

numeric, censored, or water-quality data. Missing values are permitted in either argument and result in a missing value in the output.

Details

For all comparisons, the censored data are converted to multiply censored data, class "mcens." The conversion from class "qw" preserves the strict interpretation of less-than values as greater than or equal to 0 and less than the reporting level. The distinction of being strictly less than is lost for the conversion of left-censored data, class "lcens."

Value

A logical vector the represents the result of the comparison between each element in e1 and e2.

Examples

as.lcens(c(1, 3), 2) > 1
as.lcens(c(1, 3), 2) < 4


USGS-R/smwrQW documentation built on Oct. 11, 2022, 6:13 a.m.