Create HDPS covariate settings

createHdpsCovariateSettings(useCovariateCohortIdIs1 = FALSE,
useCovariateDemographics = TRUE,
useCovariateDemographicsGender = TRUE,
useCovariateDemographicsRace = TRUE,
useCovariateDemographicsEthnicity = TRUE,
useCovariateDemographicsAge = TRUE,
useCovariateDemographicsYear = TRUE,
useCovariateDemographicsMonth = TRUE,
useCovariateConditionOccurrence = TRUE,
useCovariate3DigitIcd9Inpatient180d = FALSE,
useCovariate3DigitIcd9Inpatient180dMedF = FALSE,
useCovariate3DigitIcd9Inpatient180d75F = FALSE,
useCovariate3DigitIcd9Ambulatory180d = FALSE,
useCovariate3DigitIcd9Ambulatory180dMedF = FALSE,
useCovariate3DigitIcd9Ambulatory180d75F = FALSE,
useCovariateDrugExposure = FALSE,
useCovariateIngredientExposure180d = FALSE,
useCovariateIngredientExposure180dMedF = FALSE,
useCovariateIngredientExposure180d75F = FALSE,
useCovariateProcedureOccurrence = FALSE,
useCovariateProcedureOccurrenceInpatient180d = FALSE,
useCovariateProcedureOccurrenceInpatient180dMedF = FALSE,
useCovariateProcedureOccurrenceInpatient180d75F = FALSE,
useCovariateProcedureOccurrenceAmbulatory180d = FALSE,
useCovariateProcedureOccurrenceAmbulatory180dMedF = FALSE,
useCovariateProcedureOccurrenceAmbulatory180d75F = FALSE,
excludedCovariateConceptIds = c(), includedCovariateConceptIds = c(),
deleteCovariatesSmallCount = 100)

## Arguments

useCovariateCohortIdIs1 A boolean value (TRUE/FALSE) to determine if a covariate should be contructed for whether the cohort ID is 1 (currently primarily used in CohortMethod). A boolean value (TRUE/FALSE) to determine if demographic covariates (age in 5-yr increments, gender, race, ethnicity, year of index date, month of index date) will be created and included in future models. A boolean value (TRUE/FALSE) to determine if gender should be included in the model. A boolean value (TRUE/FALSE) to determine if race should be included in the model. A boolean value (TRUE/FALSE) to determine if ethnicity should be included in the model. A boolean value (TRUE/FALSE) to determine if age (in 5 year increments) should be included in the model. A boolean value (TRUE/FALSE) to determine if calendar year should be included in the model. A boolean value (TRUE/FALSE) to determine if calendar month should be included in the model. A boolean value (TRUE/FALSE) to determine if covariates derived from CONDITION_OCCURRENCE table will be created and included in future models. A boolean value (TRUE/FALSE) to determine if covariates will be created and used in models that look for presence/absence of condition within inpatient setting in 180d window prior to or on cohort index date. Conditions are aggregated at the ICD-9 3-digit level. Only applicable if useCovariateConditionOccurrence = TRUE. Similar to useCovariate3DigitIcd9Inpatient180d, but now only if the frequency of the ICD-9 code is higher than the median. Similar to useCovariate3DigitIcd9Inpatient180d, but now only if the frequency of the ICD-9 code is higher than the 75th percentile. A boolean value (TRUE/FALSE) to determine if covariates will be created and used in models that look for presence/absence of condition within ambulatory setting in 180d window prior to or on cohort index date. Conditions are aggregated at the ICD-9 3-digit level. Only applicable if useCovariateConditionOccurrence = TRUE. Similar to useCovariate3DigitIcd9Ambulatory180d, but now only if the frequency of the ICD-9 code is higher than the median. Similar to useCovariate3DigitIcd9Ambulatory180d, but now only if the frequency of the ICD-9 code is higher than the 75th percentile. A boolean value (TRUE/FALSE) to determine if covariates derived from DRUG_EXPOSURE table will be created and included in future models. A boolean value (TRUE/FALSE) to determine if covariates will be created and used in models that look for presence/absence of drug ingredients within inpatient setting in 180d window prior to or on cohort index date. Only applicable if useCovariateDrugExposure = TRUE. Similar to useCovariateIngredientExposure180d, but now only if the frequency of the ingredient is higher than the median. Similar to useCovariateIngredientExposure180d, but now only if the frequency of the ingredient is higher than the 75th percentile. A boolean value (TRUE/FALSE) to determine if covariates derived from PROCEDURE_OCCURRENCE table will be created and included in future models. A boolean value (TRUE/FALSE) to determine if covariates will be created and used in models that look for presence/absence of procedures within inpatient setting in 180d window prior to or on cohort index date. Only applicable if useCovariateProcedureOccurrence = TRUE. Similar to useCovariateProcedureOccurrenceInpatient180d, but now only if the frequency of the procedure code is higher than the median. Similar to useCovariateProcedureOccurrenceInpatient180d, but now only if the frequency of the procedure code is higher than the 75th percentile. A boolean value (TRUE/FALSE) to determine if covariates will be created and used in models that look for presence/absence of procedures within ambulatory setting in 180d window prior to or on cohort index date. Only applicable if useCovariateProcedureOccurrence = TRUE. Similar to useCovariateProcedureOccurrenceAmbulatory180d, but now only if the frequency of the procedure code is higher than the median. Similar to useCovariateProcedureOccurrenceAmbulatory180d, but now only if the frequency of the procedure code is higher than the 75th percentile. A list of concept IDs that should NOT be used to construct covariates. A list of concept IDs that should be used to construct covariates. A numeric value used to remove covariates that occur in both cohorts fewer than deleteCovariateSmallCounts time.

## Value

An object of type hdpsCovariateSettings, to be used in other functions.

## Details

creates an object specifying how covariates should be contructed from data in the CDM model.