diff --git a/DESCRIPTION b/DESCRIPTION index 32599e8dd..1ffa0e0f7 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,8 +2,8 @@ Type: Package Package: datapackr Title: A Package that Packs and Unpacks all Data Packs and Target Setting Tools -Version: 7.2.0 -Date: 2023-12-06 +Version: 7.2.1 +Date: 2023-12-18 Authors@R: c( person("Scott", "Jackson", , "sjackson@baosystems.com", role = c("aut", "cre")), person("Jason", "Pickering", , "jason.p.pickering@gmail.com", role = c("aut", "rev")), diff --git a/NEWS.md b/NEWS.md index 7a7da2055..0f15504b5 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,17 @@ +# datapackr 7.2.1 + +## New features +* Updates to COP24 Template + + +## Bug fixes +* Completed updates related to OPU Data Pack's conversion PSNUxIM tools +* Updated country list for COP24 Target Setting Tool Generation script +* Updated regular expression related to Year2 KP data + +## Minor improvements and fixes +* + # datapackr 7.2.0 ## New features diff --git a/R/datapackVsDatim.R b/R/datapackVsDatim.R index f7082f6b9..32b594a53 100644 --- a/R/datapackVsDatim.R +++ b/R/datapackVsDatim.R @@ -159,7 +159,7 @@ compareData_DatapackVsDatim <- if (!is.null(datim_data)) { datim_data %<>% dplyr::rename(datim_value = value) - if (d$info$tool == "OPU Data Pack") { + if (d$info$tool %in% c("OPU Data Pack", "PSNUxIM")) { ### data in OPU datapacks must have a valid Mech or dedupe mech ### so we do not compare dreams or any other data without mech datim_data <- dplyr::filter(datim_data, diff --git a/R/packTool.R b/R/packTool.R index 6d95b8a57..8a9465e09 100644 --- a/R/packTool.R +++ b/R/packTool.R @@ -74,7 +74,7 @@ packTool <- function(model_data = NULL, model_data = model_data, spectrum_data = spectrum_data, d2_session = d2_session) - } else if (d$info$tool == "OPU Data Pack") { + } else if (d$info$tool %in% c("OPU Data Pack", "PSNUxIM")) { d <- packOPUDataPack(d, undistributed_mer_data = undistributed_mer_data, diff --git a/R/prepareMemoData.R b/R/prepareMemoData.R index 3270cf9ad..dd19a1209 100644 --- a/R/prepareMemoData.R +++ b/R/prepareMemoData.R @@ -69,7 +69,7 @@ prepareExistingDataAnalytics <- function(d, d2_session = datastreams = "mer_targets", d2_session = d2_session) - if (d$info$tool == "OPU Data Pack") { + if (d$info$tool %in% c("OPU Data Pack", "PSNUxIM")) { ### OPU DataPacks only include data with a funding mechanism ### drop data with default attribute option combo df <- dplyr::filter(df, diff --git a/R/unPackPSNUxIM_API.R b/R/unPackPSNUxIM_API.R index 4a6244e99..aabf734aa 100644 --- a/R/unPackPSNUxIM_API.R +++ b/R/unPackPSNUxIM_API.R @@ -24,7 +24,7 @@ checkHasPSNUxIM <- function(d) { " all changes to other tabs of your Data Pack are complete. Once all other updates", " are complete, you may return here to update your PSNUxIM tab at any time.", "\n") - } else if (d$info$tool == "OPU Data Pack") { + } else if (d$info$tool %in% c("OPU Data Pack", "PSNUxIM")) { warning_msg <- paste0( "WARNING! Your OPU Data Pack's PSNUxIM tab appears to be empty. Please", " investigate and resubmit." diff --git a/data-raw/COP24/COP24_Data_Pack_generation_script.R b/data-raw/COP24/COP24_Data_Pack_generation_script.R index f4bad398e..4218ba410 100644 --- a/data-raw/COP24/COP24_Data_Pack_generation_script.R +++ b/data-raw/COP24/COP24_Data_Pack_generation_script.R @@ -42,7 +42,8 @@ if (NROW(compare_diffs) > 0) { } # # For Production run #### -# pick <- datapackr::cop_datapack_countries +pick <- datapackr::cop24_datapack_countries %>% + dplyr::filter(!datapack_name %in% c("Asia Region", "Western Hemisphere Region", "Turkmenistan")) # Execution #### for (i in seq_along(pick$datapack_name)) {