Xinglab / rmats2sashimiplot

GNU General Public License v2.0
135 stars 54 forks source link

Empty gff file #82

Closed eladzis closed 2 years ago

eladzis commented 2 years ago

Hello, I'm trying to run rmats2sashimiplot but the it isn't able to find the data from the bam files- the gff files are empty. An example: Indexing GFF...

Can you please pinpoint where is the problem? Thanks Elad

EricKutschera commented 2 years ago

I'm not sure what would cause Loaded 0 genes. Have you tried running with the latest code from the master branch with python ./src/rmats2sashimiplot/rmats2sashimiplot.py?

Can you post the full command you are running and all the printed output?

eladzis commented 2 years ago

I used the anaconda version so I'm not sure if it was updated or not. I ran the test samples and the program ran fine. I'm attaching the log file of the run. The first two lines in the log file are as a result of "echo $B1", "echo $B2". The rest is : rmats2sashimiplot --b1 $B1 --b2 $B2 -t ${AS_type} -e $dt_url --l1 SampleOne --l2 SampleTwo --exon_s 1 --intron_s 5 -o $dir_to_save_plots --group-info $group_dt_ur sashimi_plots_main.sh.3685974.log

Thanks for the help! Elad

EricKutschera commented 2 years ago

The output you posted looks like it is printing this line: https://github.com/Xinglab/rmats2sashimiplot/blob/master/src/rmats2sashimiplot/rmats2sashimiplot.py#L355 /sci/labs/milotem/eladzis/anaconda3/envs/rmats2sashimi/bin/python3.7 /sci/labs/milotem/eladzis/anaconda3/envs/rmats2sashimi/lib/python3.7/site-packages/MISO/misopy/sashimi_plot/sashimi_plot.py --plot-event "" /sci/labs/milotem/eladzis/Michal_Loteme/SplicingAnalysis/melanoma_bulk/rmats/sashimi_plots/plots/MGH_TCB_high_pre_MXE/Sashimi_index_chrX_1 /sci/labs/milotem/eladzis/Michal_Loteme/SplicingAnalysis/melanoma_bulk/rmats/sashimi_plots/plots/MGH_TCB_high_pre_MXE/Sashimi_index_chrX_1/sashimi_plot_settings.txt --output-dir /sci/labs/milotem/eladzis/Michal_Loteme/SplicingAnalysis/melanoma_bulk/rmats/sashimi_plots/plots/MGH_TCB_high_pre_MXE/Sashimi_plot

but where id_str is an empty string

I think that could happen if the event file given with -e had unexpected columns. Can you post the contents of $dt_url or maybe just the first few lines?

eladzis commented 2 years ago

I added three columns at the end of the table. Do you that is what caused the problem?

ID geneSymbol chr strand exonStart_0base exonEnd upstreamES upstreamEE downstreamES downstreamEE ID IJC_SAMPLE_1 SJC_SAMPLE_1 IJC_SAMPLE_2 SJC_SAMPLE_2 IncFormLen SkipFormLen PValue FDR IncLevel1 IncLevel2 IncLevelDifference Comparison From EventID ABI2 ABI2 chr2 + 204276007 204276094 204267298 204267457 204281630 204281804 44020 69,337,6,87,16,186,43 2,38,1,9,0,64,18 32,251,100,93,68,89,9,21 0,92,32,30,38,43,16,68 186 99 0.00072637097671 0.0136998121844294 0.948,0.825,0.762,0.837,1.0,0.607,0.56 1.0,0.592,0.625,0.623,0.488,0.524,0.23,0.141 0.263 high_tcb_pre O ABI2.SE.O.126198 AFMID AFMID chr17 + 76200736 76200822 76198783 76198832 76200908 76200981 29972 0,45,11,14,14,29,29 3,37,37,90,6,67,15 562,228,66,84,19,53,3,0 47,22,26,24,1,0,0,16 185 99 1.46562021675e-06 6.71563394463974e-05 0.0,0.394,0.137,0.077,0.555,0.188,0.509 0.865,0.847,0.576,0.652,0.91,1.0,1.0,0.0 -0.466 high_tcb_pre O AFMID.SE.O.112656 BAZ2B BAZ2B chr2 - 160253578 160253611 160252279 160252345 160253855 160253900 54550 8,44,38,39,65,20,17 10,0,0,0,34,0,0 13,47,2,50,47,1,40,186 34,1,25,20,1,22,3,66 132 99 0.000306645329184 0.00659551457035626 0.375,1.0,1.0,1.0,0.589,1.0,1.0 0.223,0.972,0.057,0.652,0.972,0.033,0.909,0.679 0.29 high_tcb_pre O BAZ2B.SE.O.46261

eladzis commented 2 years ago

I tried running the program without those three columns and got the same result

EricKutschera commented 2 years ago

It looks like the issue is a missing GeneID column. The first columns should be:

ID  GeneID  geneSymbol  chr strand

The code is expecting to find things by index. Adding columns at the end should be ok, but removing columns can cause an issue. This code I think will end up getting exonStart_0base instead of strand from your input and then won't write the .gff3 https://github.com/Xinglab/rmats2sashimiplot/blob/v2.0.4/src/rmats2sashimiplot/rmats2sashimiplot.py#L585

eladzis commented 2 years ago

Thanks for all your help! It is working now.