The paired model does not give very good error messages, but my guess is that it's related to this line and commit:
https://github.com/Xinglab/PAIRADISE/blob/c3334ffa593dbf26bc9428d46fd8406d190adcf9/pairadise/src/pairadise_model/R/pairadise.R#L338https://github.com/Xinglab/PAIRADISE/commit/74072346c4ab8fde00d0f5eac0727317333ab324I'm not sure of the details, but I think that somehow the calculation can end up with an Infinite number that leads to NA. You could try running with the change in that commit which should output a p-value of 1 in cases where it gets that error
You could also try running with the code modified to get more information. The message indicates that there was an unexpected NA value somewhere in the %dopar% block:
https://github.com/Xinglab/PAIRADISE/blob/c3334ffa593dbf26bc9428d46fd8406d190adcf9/pairadise/src/pairadise_model/R/pairadise.R#L129It doesn't say what line, but I think that task 24857 means the error happened for iExon=24857. If you print out the ExonID then you can find the row in the input JC.raw.input.SE.txt file with the same ID. Hopefully the error can be reproduced with just that one row
The code can also be updated to be single threaded by using a regular for loop instead of %dopar%. In that case it should give a more detailed error message. I made a branch on the PAIRADISE github that has that change:
https://github.com/Xinglab/PAIRADISE/compare/kutscherae-debug-errorIf you download that branch, you can update your PAIRADISE install and hopefully get more information about the error:
git clone
https://github.com/Xinglab/PAIRADISE.gitcd PAIRADISE
git checkout kutscherae-debug-error
R
> install.packages("./pairadise/src/pairadise_model/", repos=NULL)
Then run with the original JC.raw.input.SE.txt file to get the ExonID that goes with task 24857:
Rscript /path/to/rmats/rMATS_R/paired_model.R /path/to/original/JC.raw.input.SE.txt 1 /path/to/write/debug/output/rMATS_result_FDR.txt
That should print the ExonID at the beginning and you can CTRL-C it after that. Then create a new JC.raw.input.SE.txt file that is just the header and the line from the original with the matching ExonID and run:
Rscript /path/to/rmats/rMATS_R/paired_model.R /path/to/modified/JC.raw.input.SE.txt 1 /path/to/write/debug/output/rMATS_result_FDR.txt
Hopefully that should give a more detailed error message
Eric