From 057c1d042a87036fa59c5ed53ade34e2e798355d Mon Sep 17 00:00:00 2001 From: Erik Leppo Date: Mon, 19 Apr 2021 16:15:15 -0400 Subject: [PATCH] v2.0.5.9089 * refactor: Remove extra columns from QC routine, Issue #123 + fun.QC.R + fun.QC.File.R --- DESCRIPTION | 2 +- NEWS | 10 +++++++++- NEWS.md | 10 +++++++++- NEWS.rmd | 7 +++++++ R/fun.QC.File.R | 6 ++++++ R/fun.QC.R | 9 +++++++-- inst/shiny-examples/ContDataQC/ui.R | 2 +- 7 files changed, 40 insertions(+), 6 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index f7c67d4..ca5a16a 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: ContDataQC Title: Quality Control (QC) of Continous Monitoring Data -Version: 2.0.5.9088 +Version: 2.0.5.9089 Authors@R: c( person("Erik W", "Leppo", email="Erik.Leppo@tetratech.com",role=c("aut","cre")), person("Ann","Roseberry Lincoln", role="ctb"), diff --git a/NEWS b/NEWS index 884011c..4ece3fe 100644 --- a/NEWS +++ b/NEWS @@ -3,10 +3,18 @@ NEWS-ContDataQC - #> Last Update: 2021-04-19 13:40:53 + #> Last Update: 2021-04-19 16:11:06 # Version History +## v2.0.5.9089 + +2021-04-19 + +- refactor: Remove extra columns from QC routine, Issue \#123 + - fun.QC.R + - fun.QC.File.R + ## v2.0.5.9088 2021-04-19 diff --git a/NEWS.md b/NEWS.md index 884011c..4ece3fe 100644 --- a/NEWS.md +++ b/NEWS.md @@ -3,10 +3,18 @@ NEWS-ContDataQC - #> Last Update: 2021-04-19 13:40:53 + #> Last Update: 2021-04-19 16:11:06 # Version History +## v2.0.5.9089 + +2021-04-19 + +- refactor: Remove extra columns from QC routine, Issue \#123 + - fun.QC.R + - fun.QC.File.R + ## v2.0.5.9088 2021-04-19 diff --git a/NEWS.rmd b/NEWS.rmd index 8b34e2a..762ac4e 100644 --- a/NEWS.rmd +++ b/NEWS.rmd @@ -21,6 +21,13 @@ cat(paste0("Last Update: ",Sys.time())) # Version History +## v2.0.5.9089 +2021-04-19 + +* refactor: Remove extra columns from QC routine, Issue #123 + + fun.QC.R + + fun.QC.File.R + ## v2.0.5.9088 2021-04-19 diff --git a/R/fun.QC.File.R b/R/fun.QC.File.R index 8cfbff1..e84c92b 100644 --- a/R/fun.QC.File.R +++ b/R/fun.QC.File.R @@ -946,6 +946,12 @@ fun.QC.File <- function(fun.myFile # }##FOR.j.END # + + # Remove "Comment.MOD.Flag.*" columns (2021-04-19), Issue #123 + ## easier to remove than to mod code to not add + data.import <- data.import[, !grepl("^Comment\\.MOD\\.Flag\\." + , names(data.import))] + # # leave as a loop so get RAW and Comment together # j <- myNames.DataFields2Mod # # A. Add comment field and leave blank diff --git a/R/fun.QC.R b/R/fun.QC.R index 0adfbf5..b8ec776 100644 --- a/R/fun.QC.R +++ b/R/fun.QC.R @@ -917,12 +917,17 @@ fun.QC <- function(fun.myData.SiteID for (j in myNames.DataFields2Mod) {##FOR.j.START # # A. Add comment field and leave blank - data.import[,paste(myName.Comment.Mod,j,sep=".")] <- "" + data.import[, paste(myName.Comment.Mod, j, sep=".")] <- "" # B. Add data.RAW and populate with original data - data.import[,paste(myName.Raw,j,sep=".")] <- data.import[,j] + data.import[, paste(myName.Raw, j, sep=".")] <- data.import[, j] # }##FOR.j.END # + # Remove "Comment.MOD.Flag.*" columns (2021-04-19), Issue #123 + ## easier to remove than to mod code to not add + data.import <- data.import[, !grepl("^Comment\\.MOD\\.Flag\\." + , names(data.import))] + # # leave as a loop so get RAW and Comment together # j <- myNames.DataFields2Mod # # A. Add comment field and leave blank diff --git a/inst/shiny-examples/ContDataQC/ui.R b/inst/shiny-examples/ContDataQC/ui.R index 88ebadb..d0520bf 100644 --- a/inst/shiny-examples/ContDataQC/ui.R +++ b/inst/shiny-examples/ContDataQC/ui.R @@ -17,7 +17,7 @@ tab_Console <- source("external/tab_Console.R", local = TRUE)$value shinyUI( # VERSION ---- - navbarPage("Continuous data QC, summary, and statistics - v2.0.5.9087", + navbarPage("Continuous data QC, summary, and statistics - v2.0.5.9088", theme= shinytheme("spacelab"), #also liked "cerulean" at https://rstudio.github.io/shinythemes/ # tabPan, Site Intro ----