Skip to content

Commit

Permalink
Merge pull request #155 from USEPA/cm-release-review
Browse files Browse the repository at this point in the history
Harmonize tab updates
  • Loading branch information
cristinamullin authored May 31, 2024
2 parents 9e5c5b5 + e09c26e commit 77fcd96
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 14 deletions.
6 changes: 3 additions & 3 deletions R/mod_censored_data.R
Original file line number Diff line number Diff line change
Expand Up @@ -264,16 +264,16 @@ mod_censored_data_server <- function(id, tadat) {
dat[, c(
"ResultIdentifier",
"TADA.CharacteristicName",
"TADA.DetectionQuantitationLimitMeasure.MeasureValue",
"DetectionQuantitationLimitMeasure.MeasureValue",
"DetectionQuantitationLimitMeasure.MeasureUnitCode",
"TADA.ResultMeasureValue",
"TADA.ResultMeasure.MeasureUnitCode"
)]
dat <-
dat %>% dplyr::rename(
"Estimated Detection Limit Value" = TADA.ResultMeasureValue,
"Original Detection Limit Value" = TADA.DetectionQuantitationLimitMeasure.MeasureValue,
"Original Detection Limit Value" = DetectionQuantitationLimitMeasure.MeasureValue,
"Original Unit" = DetectionQuantitationLimitMeasure.MeasureUnitCode,
"Estimated Detection Limit Value" = TADA.ResultMeasureValue,
"Estimated Unit" = TADA.ResultMeasure.MeasureUnitCode
)
censdat$exdat <-
Expand Down
20 changes: 10 additions & 10 deletions R/mod_harmonize_np.R
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ mod_harmonize_np_server <- function(id, tadat) {
"Target.TADA.MethodSpeciationName",
"TADA.SpeciationAssumptions",
"Target.TADA.SpeciationConversionFactor",
"TADA.ResultMeasure.MeasureUnitCode",
"Target.TADA.ResultMeasure.MeasureUnitCode",
"Target.TADA.UnitConversionFactor",
#"TADA.ResultMeasure.MeasureUnitCode", #no longer in harmonization template
#"Target.TADA.ResultMeasure.MeasureUnitCode", #no longer in harmonization template
#"Target.TADA.UnitConversionFactor", #no longer in harmonization template
"HarmonizationGroup"
)

Expand All @@ -77,9 +77,9 @@ mod_harmonize_np_server <- function(id, tadat) {
Target.TADA.MethodSpeciationName = "Target Speciation",
TADA.SpeciationAssumptions = "Speciation Assumptions",
Target.TADA.SpeciationConversionFactor = "Speciation Conversion Factor (to AS N or AS P)",
TADA.ResultMeasure.MeasureUnitCode = "Unit",
Target.TADA.ResultMeasure.MeasureUnitCode = "Target Unit",
Target.TADA.UnitConversionFactor = "Unit Conversion Factor",
# TADA.ResultMeasure.MeasureUnitCode = "Unit",
# Target.TADA.ResultMeasure.MeasureUnitCode = "Target Unit",
# Target.TADA.UnitConversionFactor = "Unit Conversion Factor",
HarmonizationGroup = "Harmonization Group"
)
harm$ref <- ref
Expand Down Expand Up @@ -123,9 +123,9 @@ mod_harmonize_np_server <- function(id, tadat) {
Target.TADA.MethodSpeciationName = "Target Speciation",
TADA.SpeciationAssumptions = "Speciation Assumptions",
Target.TADA.SpeciationConversionFactor = "Speciation Conversion Factor (to AS N or AS P)",
TADA.ResultMeasure.MeasureUnitCode = "Unit",
Target.TADA.ResultMeasure.MeasureUnitCode = "Target Unit",
Target.TADA.UnitConversionFactor = "Unit Conversion Factor",
# TADA.ResultMeasure.MeasureUnitCode = "Unit",
# Target.TADA.ResultMeasure.MeasureUnitCode = "Target Unit",
# Target.TADA.UnitConversionFactor = "Unit Conversion Factor",
HarmonizationGroup = "Harmonization Group"
)
harm$ref <- ref
Expand Down Expand Up @@ -157,7 +157,7 @@ mod_harmonize_np_server <- function(id, tadat) {
selection = "none", rownames = FALSE
) %>%
DT::formatStyle(columns = names(harm$ref), `font-size` = "12px") %>%
DT::formatStyle(columns = c("TADA.CharacteristicName", "TADA.ResultSampleFractionText", "TADA.MethodSpeciationName", "TADA.ResultMeasure.MeasureUnitCode"), backgroundColor = "#2e6da4", color = "white")
DT::formatStyle(columns = c("TADA.CharacteristicName", "TADA.ResultSampleFractionText", "TADA.MethodSpeciationName"), backgroundColor = "#2e6da4", color = "white")
})

# apply synonym ref to data when button is pushed
Expand Down
3 changes: 2 additions & 1 deletion R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,6 @@ utils::globalVariables(c(
"nd_method", "nd_mult", "od_method", "org_table",
"organization", "original_source", "project", "sampleMedia",
"selected_filters", "selected_flags", "siteType",
"siteid", "startDate", "statecode", "od_mult", "field_sel"
"siteid", "startDate", "statecode", "od_mult", "field_sel",
"DetectionQuantitationLimitMeasure.MeasureValue"
))

0 comments on commit 77fcd96

Please sign in to comment.