diff --git a/DESCRIPTION b/DESCRIPTION index ff5a0d9..dc1034c 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: BioMonTools Type: Package Title: Tools for Biomonitoring and Bioassessment -Version: 1.0.2.9063 +Version: 1.0.2.9064 Author: c( person("Erik W.", "Leppo", email="Erik.Leppo@tetratech.com", role=c("aut","cre")), person("Jen", "Stamp", role="ctb"), diff --git a/NEWS b/NEWS index 85b7952..2a4a193 100644 --- a/NEWS +++ b/NEWS @@ -4,10 +4,16 @@ NEWS - #> Last Update: 2024-11-06 08:28:24.319915 + #> Last Update: 2024-11-06 10:12:51.279687 # Version History +## Changes in version 1.0.2.9064 (2024-11-06) + +- refactor: Add new fish metric (pi_BCG2_att1234b) + - MetricNames.xlsx + - metric_values.R + ## Changes in version 1.0.2.9063 (2024-11-06) - docs: Update comment about NATIVE in metric.values help diff --git a/NEWS.md b/NEWS.md index 85b7952..2a4a193 100644 --- a/NEWS.md +++ b/NEWS.md @@ -4,10 +4,16 @@ NEWS - #> Last Update: 2024-11-06 08:28:24.319915 + #> Last Update: 2024-11-06 10:12:51.279687 # Version History +## Changes in version 1.0.2.9064 (2024-11-06) + +- refactor: Add new fish metric (pi_BCG2_att1234b) + - MetricNames.xlsx + - metric_values.R + ## Changes in version 1.0.2.9063 (2024-11-06) - docs: Update comment about NATIVE in metric.values help diff --git a/NEWS.rmd b/NEWS.rmd index 65f38ee..c262dee 100644 --- a/NEWS.rmd +++ b/NEWS.rmd @@ -18,6 +18,12 @@ cat(paste0("Last Update: ",Sys.time())) # Version History +## Changes in version 1.0.2.9064 (2024-11-06) + +* refactor: Add new fish metric (pi_BCG2_att1234b) + + MetricNames.xlsx + + metric_values.R + ## Changes in version 1.0.2.9063 (2024-11-06) * docs: Update comment about NATIVE in metric.values help diff --git a/R/metric_values.R b/R/metric_values.R index dfb0cc3..c90fe59 100644 --- a/R/metric_values.R +++ b/R/metric_values.R @@ -4608,6 +4608,13 @@ metric.values.fish <- function(myDF | BCG_ATTR == "3" | BCG_ATTR == "4")] , na.rm = TRUE) / ni_total + , pi_BCG2_att1234b = 100 * (sum(N_TAXA[(BCG_ATTR == "1" + | BCG_ATTR == "2" + | BCG_ATTR == "3" + | BCG_ATTR == "4")] + , na.rm = TRUE) + + sum(N_TAXA[BCG_ATTR2 == "4_BETTER"] + , na.rm = TRUE)) / ni_total , pi_BCG_att1236 = 100 * sum(N_TAXA[(BCG_ATTR == "1" | BCG_ATTR == "2" | BCG_ATTR == "3" diff --git a/inst/extdata/MetricNames.xlsx b/inst/extdata/MetricNames.xlsx index 2616bd1..9073ae7 100644 Binary files a/inst/extdata/MetricNames.xlsx and b/inst/extdata/MetricNames.xlsx differ diff --git a/inst/shiny-examples/BioMonTools/global.R b/inst/shiny-examples/BioMonTools/global.R index df7c4ec..ab56012 100644 --- a/inst/shiny-examples/BioMonTools/global.R +++ b/inst/shiny-examples/BioMonTools/global.R @@ -1,7 +1,7 @@ # Shiny Global File # Version ---- -pkg_version <- "1.0.2.9063" +pkg_version <- "1.0.2.9064" # Packages---- library(BioMonTools)