Skip to content

Commit a1817d4

Browse files
committed
updates
1 parent 04b9978 commit a1817d4

File tree

1 file changed

+12
-16
lines changed

1 file changed

+12
-16
lines changed

R/executeDiagnostics.R

+12-16
Original file line numberDiff line numberDiff line change
@@ -609,16 +609,12 @@ executeDiagnostics <- function(cohortDefinitionSet,
609609
stop("Cohort table is empty")
610610
}
611611

612-
cohortCounts <- makeDataExportable(
613-
x = cohortCounts,
614-
tableName = "cohort_count",
615-
minCellCount = minCellCount,
616-
databaseId = databaseId
617-
)
618-
619-
writeToCsv(
612+
cohortCounts <- exportDataToCsv(
620613
data = cohortCounts,
614+
tableName = "cohort_count",
621615
fileName = file.path(exportFolder, "cohort_count.csv"),
616+
minCellCount = minCellCount,
617+
databaseId = databaseId,
622618
incremental = FALSE,
623619
cohortId = cohorts$cohortId
624620
)
@@ -713,11 +709,11 @@ executeDiagnostics <- function(cohortDefinitionSet,
713709
if (runIncludedSourceConcepts || runOrphanConcepts || runBreakdownIndexEvents) {
714710
timeExecution(
715711
exportFolder,
716-
taskName = "runConceptSetDiagnostics",
712+
taskName = "runIncludedSourceConcepts",
717713
cohortIds,
718714
parent = "executeDiagnostics",
719715
expr = {
720-
runConceptSetDiagnostics(
716+
runIncludedSourceConcepts(
721717
connection = connection,
722718
tempEmulationSchema = tempEmulationSchema,
723719
cdmDatabaseSchema = cdmDatabaseSchema,
@@ -749,11 +745,11 @@ executeDiagnostics <- function(cohortDefinitionSet,
749745
if (runTimeSeries) {
750746
timeExecution(
751747
exportFolder,
752-
"executeTimeSeriesDiagnostics",
748+
"runTimeSeries",
753749
cohortIds,
754750
parent = "executeDiagnostics",
755751
expr = {
756-
executeTimeSeriesDiagnostics(
752+
runTimeSeries(
757753
connection = connection,
758754
tempEmulationSchema = tempEmulationSchema,
759755
cdmDatabaseSchema = cdmDatabaseSchema,
@@ -804,11 +800,11 @@ executeDiagnostics <- function(cohortDefinitionSet,
804800
if (runIncidenceRate) {
805801
timeExecution(
806802
exportFolder,
807-
"computeIncidenceRates",
803+
"runIncidenceRate",
808804
cohortIds,
809805
parent = "executeDiagnostics",
810806
expr = {
811-
computeIncidenceRates(
807+
runIncidenceRate(
812808
connection = connection,
813809
tempEmulationSchema = tempEmulationSchema,
814810
cdmDatabaseSchema = cdmDatabaseSchema,
@@ -831,11 +827,11 @@ executeDiagnostics <- function(cohortDefinitionSet,
831827
if (runCohortRelationship) {
832828
timeExecution(
833829
exportFolder,
834-
"executeCohortRelationshipDiagnostics",
830+
"runCohortRelationship",
835831
cohortIds,
836832
parent = "executeDiagnostics",
837833
expr = {
838-
executeCohortRelationshipDiagnostics(
834+
runCohortRelationship(
839835
connection = connection,
840836
databaseId = databaseId,
841837
exportFolder = exportFolder,

0 commit comments

Comments
 (0)