Coder Social home page Coder Social logo

Comments (9)

jduke99 avatar jduke99 commented on June 12, 2024

Here is my platform information:

R version 3.2.2 (2015-08-14) -- "Fire Safety"
Platform: x86_64-apple-darwin13.4.0 (64-bit)

from cohortmethod.

schuemie avatar schuemie commented on June 12, 2024

Hi Jon. This seems like a know issue, where one of the data sets retrieved has zero rows. Most likely there are no outcomes at all for your cohorts of interest.

Instead of trying to add workarounds for all situations like these, I've decided to try and solve the root cause: ff doesn't allow zero row objects. I'm working with the original developers of ff, but it is slow progress.

from cohortmethod.

jduke99 avatar jduke99 commented on June 12, 2024

Thanks Martijn. So this points perhaps to my own lack of understanding of setting up a CM run. I have created three cohorts (using Circe). Here they are on ohdsi.org if helpful:

Target - http://www.ohdsi.org/web/circe/#/814
Comparator - http://www.ohdsi.org/web/circe/#/815
Outcome - http://www.ohdsi.org/web/circe/#/816

I have confirmed that all three cohorts have been generated in my database and that there is overlap of subject_ids between my target / comparator and outcome cohorts (doing SQL joins to check).

I moved these three cohorts to a dedicated table (cath_study). I reference the local cohort__definition_ids in my CM configuration. I did not use any exclusion criteria in this particular run, just to test it out. But I am trying to understand why my data frame would be empty. My configuration is in the post above. Am I missing something (or alternatively have left in a configuration that I should have taken out)?

from cohortmethod.

jduke99 avatar jduke99 commented on June 12, 2024

I will close issue and post this question via the forums.

from cohortmethod.

schuemie avatar schuemie commented on June 12, 2024

Hi Jon. You may want to try the latest version of CohortMethod. I found that I had not considered situations where people have outcomes, but no prior outcomes, and because of the ff limitations that again led to an error. The new version has a workaround (but I really need to get the ff package fixed).

from cohortmethod.

jduke99 avatar jduke99 commented on June 12, 2024

Thank you Martijn. That was my study exactly-- no prior outcomes, all are post. I will install and re-run with the latest.

One thought: Would it make sense to do a "check" for empty outcomes at the beginning of the process rather than later? And if empty, just jump out before churning through all the covariates?

from cohortmethod.

jduke99 avatar jduke99 commented on June 12, 2024

@schuemie , I got this error when trying to load the updated CohortMethod. I deleted and re-installed the package and still the same error. I figured since it is a corruption issue it was related to my folders, but I go the same error on my Mac and PC. Any ideas?

library(CohortMethod)
Error in get(method, envir = home) :
lazy-load database '/Library/Frameworks/R.framework/Versions/3.2/Resources/library/CohortMethod/R/CohortMethod.rdb' is corrupt
In addition: Warning messages:
1: In .registerS3method(fin[i, 1], fin[i, 2], fin[i, 3], fin[i, 4], :
restarting interrupted promise evaluation
2: In get(method, envir = home) :
restarting interrupted promise evaluation
3: In get(method, envir = home) : internal error -3 in R_decompress1
Error: package or namespace load failed for ‘CohortMethod’

from cohortmethod.

schuemie avatar schuemie commented on June 12, 2024

Ughhh, I don't understand what is happening. I can reinstall and load CohortMethod just fine on my machine. The problem seems to be an R problem, although I have no clue why it is happening on both your Mac and PC.

Some googling on this problem suggests most people solve it by restarting R, but you've tried that. Here they suggest unloading the package and then restarting R. You can unload the package using

detach("package:CohortMethod", unload = TRUE)

from cohortmethod.

jduke99 avatar jduke99 commented on June 12, 2024

Okay, detached, uninstalled, quit R, restarted, reinstalled, and it all appears to work this time. :)

Will re-run with my analysis from the other day and see how things go.

from cohortmethod.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.