Learn R Programming

Covid19Wastewater (version 1.0.1)

removeOutliers: Add column with NA values where the data was flagged

Description

Add column with NA values where the data was flagged

Usage

removeOutliers(DF, Messure, Filtcol, outputColName)

Value

DF with new column without the flagged values

Arguments

DF

DF containing the columns Measure and Filtcol

Messure

The original measurement we want to keep inliers for

Filtcol

the column containing the Boolean info needed to remove outliers

outputColName

the name for the clean column

Examples

Run this code
data(Example_data, package = "Covid19Wastewater")
Example_data$site = "Madison"
df_data <- computeJumps(Example_data)
ranked_data <- rankJumps(df_data)
ranked_quantile_data <- computeRankQuantiles(ranked_data)
classied_data <- flagOutliers(ranked_quantile_data, 9)
removeOutliers(classied_data, sars_cov2_adj_load_log10, FlaggedOutlier, sars_adj_log10_Filtered)

Run the code above in your browser using DataLab