OHDSI Home | Forums | Wiki | Github

Error in executing multipleAnalyses of CohortMethod

Hi.

I am executing cohortmethod package of multipleanalyses and just following the vignette line by line with exchanging original arguments to new argument of client environment and study protocol. But, I am stuck in error of runCmAnalyses.

The errorReports are followed.

DBMS:
sql server

Error:
object ‘is.factor.ff’ is not exported by ‘namespace:ff’

SQL:
SELECT *
FROM (
SELECT row_id, covariate_id, covariate_value FROM #cov_1 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_2 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_3 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_4 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_5 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_6 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_7 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_8 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_9 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_10 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_11 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_12 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_13 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_14 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_15 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_16 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_17 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_18 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_19 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_20 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_21 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_22 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_23 UNION ALL
SELECT row_id, covariate_id, covariate_value FROM #cov_24
) all_covariates;

R version:
R version 4.0.2 (2020-06-22)

Platform:
x86_64-w64-mingw32

Attached base packages:

  • stats
  • graphics
  • grDevices
  • utils
  • datasets
  • methods
  • base

Other attached packages:

  • CohortMethod (3.0.2)
  • FeatureExtraction (2.2.3)
  • Cyclops (3.0.0)
  • DatabaseConnector (2.3.0)

And the Traceback of debugging the runCmAnalyses

Error in base::try(analysisSum, TRUE) : object ‘analysisSum’ not found
16.
stop(paste(“Error executing SQL:”, message, paste("An error report has been created at ", fileName), sep = “\n”), call. = FALSE)
15.
.createErrorReport(connection@dbms, err$message, sql, errorReportFile)
14.
value[3L]
13.
tryCatchOne(expr, names, parentenv, handlers[[1L]])
12.
tryCatchList(expr, classes, parentenv, handlers)
11.
tryCatch({ result ← lowLevelQuerySql.ffdf(connection, sqlStatements[1]) colnames(result) ← toupper(colnames(result)) result ← convertFields(connection@dbms, result) …
10.
DatabaseConnector::querySql.ffdf(connection, sql)
9.
(function (connection, oracleTempSchema = NULL, cdmDatabaseSchema, cohortTable = “#cohort_person”, cohortId = -1, cdmVersion = “5”, rowIdField = “subject_id”, covariateSettings, targetDatabaseSchema, targetCovariateTable, targetCovariateRefTable, targetAnalysisRefTable, …
8.
do.call(eval(parse(text = fun)), args)
7.
FeatureExtraction::getDbCovariateData(connection = connection, oracleTempSchema = oracleTempSchema, cdmDatabaseSchema = cdmDatabaseSchema, cdmVersion = cdmVersion, cohortTable = cohortTable, cohortTableIsTemp = TRUE, rowIdField = “row_id”, covariateSettings = covariateSettings)
6.
getDbCohortMethodData(connectionDetails = structure(list(dbms = “sql server”, user = “xxxx”, password = “xxxxx”, server = “xxx.xxx.xxx.xxx”, oracleDriver = “thin”), class = “connectionDetails”), cdmDatabaseSchema = “xxx.dbo”, oracleTempSchema = “xxx.dbo”, exposureDatabaseSchema = “xxx.dbo”, …
5.
do.call(“getDbCohortMethodData”, params$args)
4.
FUN(X[[i]], …)
3.
lapply(x, fun, …)
2.
ParallelLogger::clusterApply(cluster, objectsToCreate, createCmDataObject)
1.
runCmAnalyses(connectionDetails = connectionDetails, cdmDatabaseSchema = cdmDatabaseSchema, exposureDatabaseSchema = cdmDatabaseSchema, exposureTable = “drug_era”, outcomeDatabaseSchema = resultsDatabaseSchema, outcomeTable = “outcomes”, cdmVersion = 5, outputFolder = outputFolder, cmAnalysisList = cmAnalysisList, …

Thank you for your helps. :slight_smile:

t