Giter Club home page Giter Club logo

neelsoumya / dssurvival Goto Github PK

View Code? Open in Web Editor NEW
5.0 6.0 11.0 4.36 MB

Survival functions for DataSHIELD. Package for building survival models, Cox proportional hazards models and Cox regression models in DataSHIELD.

Home Page: https://neelsoumya.github.io/dsSurvivalbookdown/

License: GNU General Public License v3.0

R 97.22% TeX 2.78%
survival-analysis datashield cox-models cox-regression clinical-informatics meta-analysis survival-models datashield-technical-team survival-functions r datashield-testing dssurvival

dssurvival's Issues

invalid documentation

The installation of Datashield packages does not fit to the current OPAL version

Try to install this R package in a current OPAL (version 4.4.10)

Expected behavior
The documentation of this package does not fit to the dialogs from OPAL; see screenshots of the current forms

Screenshots
grafik
grafik

Desktop (please complete the following information):
does not matter

Smartphone (please complete the following information):
does not matter

Additional context
Please update the installation procedures or create multiple versions if you want to keep the old versions, too

confirm deterministic technique

In the prototyping code, 2 difference approaches are tested for the deterministic anonymisation. The first applies the process to the individuals before Kaplan-Meier, the second applies it afterwards (ie to groups of individuals with the same survivla/ censoring time)

Here it looks like we have the first method. I am not sure if it makes any difference which one is used but it would be good to at least state which was chosen.

Remove the DataSHIELD options that are duplicated from dsBase

At the moment the DataSHIELD options are duplicated from dsBase. I think the options defined by this package should only be those that are unique to this package (which there aren't any currently). Otherwise you might get a conflict between this package and dsBase.

This should work ok if dsBase is a dependency.

prepare for version 2.0 release

prepare for version 2.0 release

update DESCRIPTION file with new version

update README with release notes and description for v2.0

update README and remove privacy_survival_curves branch references anywhere

minimum version of the survival dependency

We got the following error with the ds.cox.zphSLMA function and we found out that this particular cohort had version 2.44-1.1 of the survival package. In another cohort with version 3.2-11 of the survival the function worked fine. So I suggest you to specify a minimum required version of the survival package in the DESCRIPTION file

[1] "Command 'cox.zphSLMADS("coxph_serverside", "km", FALSE, FALSE, TRUE)' failed on 'moba': Error while evaluating 'dsSurvival::cox.zphSLMADS("coxph_serverside", "km", FALSE, FALSE, TRUE)' -> Error in survival::cox.zph(fit = fit_model, transform = transform, terms = terms, : \n unused arguments (terms = terms, singledf = singledf)\n"

Rationalise coxphSLMAassignDS and coxphSLMADS

coxphSLMAassignDS is designed to store a Cox model on the server side (assign) and coxphSLMADS is designed to return a summary of a Cox model (aggregate)

The only line that should be different is 207, where one returns the summary and the other the complete object.

There are some other differences, though, around these lines:

	    control <- gsub("~ bbbb", "", control, fixed = TRUE)
	    control <- gsub("~", "", control, fixed = TRUE)
	    control <- gsub("bbbb", "", control, fixed = TRUE)     

compared with:

control <- gsub("~bbbb", "", control, fixed = TRUE) 

I think this second one will miss ~ bbbb

Also in terms of maintainability, there should probably be a single function that generates the Cox model and applies the disclosure control (this might be called coxphSLMADS). Then there should be two other functions for the aggregate and assign operations, that call the main function. The aggregate would just call the main function, then do summary() on the coxph object and return to the client. The assign just returns the coxph object which stores it on the server side. That way the bulk of the code is in one place.

dsBase dependency missing

According to what I can see in the source code, this package depends on dsBase. You should specify it in the DESCRIPTION file (with I guess a minimum version of dsBase). It is also not necessary to repeat the DataSHIELD Options settings that are already defined by dsBase.

Incorrect meta analysis in tutorial?

Hi,
Is the code for performing the meta analysis (found here) correct?

Should it not be

input_logHR = c(coxph_model_full$server1$coefficients[1,1], 
        coxph_model_full$server2$coefficients[1,1], 
        coxph_model_full$server3$coefficients[1,1])
        
input_se    = c(coxph_model_full$server1$coefficients[1,3], 
        coxph_model_full$server2$coefficients[1,3], 
        coxph_model_full$server3$coefficients[1,3])
        
meta_model <- metafor::rma(input_logHR, sei = input_se, method = 'REML')

and

metafor::forest.rma(x = meta_model, digits = 4, atransf=exp) 

? Otherwise you're combining exp(coef) with se(coef) rather than coef and se(coef).

Add vcov functionality

In standard R with the survival package one can get the variance-covariance matrix using vconv()

In a future version of dsSurvival this should be added. If the model is stored on the server, then it is a case of running vcov() on that model and returning the results.

If the model itself has passed the disclosure checks, then it should be OK to release these summary statistics.

listDisclosureSettingsDS() duplicated from dsBase

Describe the bug
listDisclosureSettingsDS() is duplicated from dsBase. Given that this package imports dsBase, listDisclosureSettingsDS() should be used from there

To Reproduce
Steps to reproduce the behavior:

  1. Load dsBase library
  2. Load dsSurvival library

dsomics_testing-rserver-1 | Attaching package: ‘dsSurvival’
dsomics_testing-rserver-1 |
dsomics_testing-rserver-1 | The following object is masked from ‘package:dsBase’:
dsomics_testing-rserver-1 |
dsomics_testing-rserver-1 | listDisclosureSettingsDS

Expected behavior
No message about duplicated functions

Wrong package version

Hi,

The DESCRIPTION file states that the package version is 6.2.0-1 whereas the tag is v1.0.0.

Check the disclosiveness of n.risk, n.events

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

ds.cox.zphSLMA(fit = 'coxph_serverside') hangs

Calling ds.cox.zphSLMA(fit = 'coxph_serverside') doesn't appear to work. I get the following message, but it just stays at this point without progressing:

Getting aggregate Study1 (cox.zphSLMADS("coxph_serverside", "km", TRUE, FALSE, TRUE)) []  25% ...

ds.coxphSummary(x = 'coxph_serverside') works fine, so I know the variable is at least on the server. Is there a way to debug what is happening?

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.