OHDSI / SelfControlledCaseSeries

An R package for performing Self-Controlled Case Series (SCCS) analyses in an observational database in the OMOP Common Data Model.
http://ohdsi.github.io/SelfControlledCaseSeries
13 stars 8 forks source link

Fix computeMdrr function #28

Closed schuemie closed 2 years ago

schuemie commented 2 years ago

Fix typo here, and make function not throw error when there is no covariate with exposureCovariateId. Can count the number of exposed using

nExposed <- sccsIntervalData$covariates %>% 
      filter(covariateId == exposureCovariateId) %>%
      count() %>%
      pull()