vastgroup / vast-tools

A toolset for profiling alternative splicing events in RNA-Seq data.
MIT License
77 stars 28 forks source link

diff module: MV calculation does not work in the provided containers? #85

Closed AngryMaciek closed 4 years ago

AngryMaciek commented 4 years ago

Dear Authors,

Long time ago I cloned vast-tools from github and after the initial setup everything worked fine. I used it a lot and for the sake of reproducibility and time I decided to write a snakemake pipeline for my splicing analyses. I see now that you provide a docker container with vast-tools installed which is even cooler as snakemake has a flag --use-singularity that will automatically download an image from dockerhub and convert it to a singularity container. Every step of the pipeline, thus every vast-tools command is then executed within that container.

I did build the pipeline successfully and it run through on some sample dataset. It is only after a closer inspection that I realized that something is wrong: in the output table of the diff module all values in the whole column with MV scores are exactly zero. Since the table gets generated properly and the E[dPsi] values are indeed calculated I assume that it is a bug in vast-tools script and it is not related to the snakemake nor containers.

Please take a look yourself; below I attach a link to the inclusion table I get after combine step: https://drive.google.com/file/d/1FBHekpvXAh7O5ZLPi0WDhBAVOclawMdg/view?usp=sharing

In my workstation it is located inside a directory output_dir. One level above that I enter the singularity container(*) which was created automatically by snakemake and I execute vast-tools diff: Singularity de94136e4d85bd76bc85127d821d55fb.simg:~/snakemake_pipelines/vast_tools> vast-tools diff -o output_dir -a GSM1502498_2,GSM1502499_2 -b GSM1502500_2,GSM1502501_2 -e 10 -c 8 -r 80

The log I get during the command's execution:

readline() on closed filehandle VERSION at /usr/local/bin/vast-tools line 65.
Use of uninitialized value $version in scalar chomp at /usr/local/bin/vast-tools line 66.
Trying to load required package: optparse
Trying to load required package: MASS
Trying to load required package: RColorBrewer
Trying to load required package: reshape2
Trying to load required package: ggplot2
Trying to load required package: grid
Trying to load required package: parallel

The command ends with no error and in the output_dir I have now diff results: an empty pdf file and the following table: https://drive.google.com/file/d/1bFpoDy1Cu2BnxvdNMb4YsAzB4D65EBbS/view?usp=sharing

It would be really nice if you could execute diff yourself on my inclusion table and please let me know if I am doing something wrong or either confirm that it is a bug not on my side... Some of the points in my research depend on the MV score and for the sake of reproducibility it is very important for me to have a working version of vast-tools with diff module.

(*) I pulled docker://vastgroup/vast-tools:latest but I have also tried v2.2.2 and v2.2.0 - the problem remains the same

mirimia commented 4 years ago

Thanks for the heads up, Maciek. I personally don't use diff (I always use compare), so @UBrau is probably the most adequate current user to take a look, if the issue is related to diff. If it's an issue with the Docker container itself, then @toniher can probably check this.

Thanks Manu

toniher commented 4 years ago

Hello @AngryMaciek , I attach the following output with this command using your inclusion table:

singularity build vast.sif docker://vastgroup/vast-tools:latest
singularity exec -e vast.sif vast-tools diff -o output_dir -a GSM1502498_2,GSM1502499_2 -b GSM1502500_2,GSM1502501_2 -e 10 -c 8 -r 80

INCLUSION_LEVELS_FULL-Hsa4-hg38.DIFF.zip

It's not exactly as yours, but all values of last column are 0

$ cut -f6 INCLUSION_LEVELS_FULL-Hsa4-hg38.DIFF.txt|sort -u
0
MV[dPsi]_at_80

Resulting PDF is not 0 size, but it seems broken anyway...

@UBrau could you try in your system? In case it worked, maybe we would need to adjust software versions in the container.

$ singularity exec -e vast.sif R --version
R version 3.3.3 (2017-03-06) -- "Another Canoe"

$ singularity exec -e vast.sif perl --version

This is perl 5, version 20, subversion 2 (v5.20.2) built for x86_64-linux-gnu-thread-multi
UBrau commented 4 years ago

Hi @AngryMaciek, The -r option is supposed to be a number < 1 (e.g. the default is 0.95). In your data, when using -r 0.8, there are 3,132 differential events; with the default of 0.95 (which I would recommend) there are 1,447 events. I will add an input check to diff.