diff --git a/DESCRIPTION b/DESCRIPTION index f3b2113..2c92973 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -2,7 +2,7 @@ Package: Characterization Type: Package Title: Implement Descriptive Studies Using the Common Data Model Version: 2.1.2 -Date: 2024-2-20 +Date: 2025-2-20 Authors@R: c( person("Jenna", "Reps", , "jreps@its.jnj.com", role = c("aut", "cre")), person("Patrick", "Ryan", , "ryan@ohdsi.org", role = c("aut")), diff --git a/R/AggregateCovariates.R b/R/AggregateCovariates.R index dc2b1fb..b537c9a 100644 --- a/R/AggregateCovariates.R +++ b/R/AggregateCovariates.R @@ -26,7 +26,7 @@ #' @param casePreTargetDuration The number of days prior to case index we use for FeatureExtraction #' @param casePostOutcomeDuration The number of days prior to case index we use for FeatureExtraction #' @param extractNonCaseCovariates Whether to extract aggregate covariates and counts for patients in the targets and outcomes in addition to the cases -#' @family {Aggregate} +#' @family Aggregate #' @return #' A list with the settings #' diff --git a/R/Database.R b/R/Database.R index aa55374..3e3640b 100644 --- a/R/Database.R +++ b/R/Database.R @@ -294,6 +294,7 @@ createCharacterizationTables <- function( # add database migration here in the future migrateDataModel( connectionDetails = connectionDetails, + connection = conn, databaseSchema = resultSchema, tablePrefix = tablePrefix ) @@ -301,7 +302,12 @@ createCharacterizationTables <- function( } -migrateDataModel <- function(connectionDetails, databaseSchema, tablePrefix = "") { +migrateDataModel <- function( + connectionDetails, + connection, + databaseSchema, + tablePrefix = "" + ) { ParallelLogger::logInfo("Migrating data set") migrator <- getDataMigrator( connectionDetails = connectionDetails, @@ -319,8 +325,10 @@ migrateDataModel <- function(connectionDetails, databaseSchema, tablePrefix = "" dbms = connectionDetails$dbms ) - connection <- DatabaseConnector::connect(connectionDetails = connectionDetails) - on.exit(DatabaseConnector::disconnect(connection)) + if(missing(connection)){ + connection <- DatabaseConnector::connect(connectionDetails = connectionDetails) + on.exit(DatabaseConnector::disconnect(connection)) + } DatabaseConnector::executeSql(connection, updateVersionSql) } diff --git a/R/ViewShiny.R b/R/ViewShiny.R index 961d5db..ed6d772 100644 --- a/R/ViewShiny.R +++ b/R/ViewShiny.R @@ -6,7 +6,7 @@ #' Input is the output of ... #' @param resultFolder The location of the csv results #' @param cohortDefinitionSet The cohortDefinitionSet extracted using webAPI -#' @family {Shiny} +#' @family Shiny #' #' @return #' Opens a shiny app for interactively viewing the results diff --git a/_pkgdown.yml b/_pkgdown.yml index cb85935..028d335 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -73,3 +73,7 @@ reference: desc: > Code to run incremetal model contents: has_concept("Incremental") + - title: "Helpers" + desc: > + Helper functions such as example data for users + contents: has_concept("helper") diff --git a/man/createAggregateCovariateSettings.Rd b/man/createAggregateCovariateSettings.Rd index 629b127..eb23cb9 100644 --- a/man/createAggregateCovariateSettings.Rd +++ b/man/createAggregateCovariateSettings.Rd @@ -88,4 +88,4 @@ aggregateSetting <- createAggregateCovariateSettings( ) } -\concept{{Aggregate}} +\concept{Aggregate} diff --git a/man/viewCharacterization.Rd b/man/viewCharacterization.Rd index 2e7dd38..152a7e8 100644 --- a/man/viewCharacterization.Rd +++ b/man/viewCharacterization.Rd @@ -50,4 +50,4 @@ viewCharacterization( } -\concept{{Shiny}} +\concept{Shiny}