Xinglab / rmats-turbo

Other
221 stars 53 forks source link

pairadise computes p-value problems #350

Open forever-happy-h opened 9 months ago

forever-happy-h commented 9 months ago

Hi Eric Kutschera,

When I extract the result file RI.MATS.JC.txt then extract the key information in it, as shown below:

RI.p<-RI[,c("ID", "IJC_SAMPLE_1", "SJC_SAMPLE_1", "IJC_SAMPLE_2",

  • "SJC_SAMPLE_2", "IncFormLen", "SkipFormLen")]

But when I use pairadise to calculate the p-value. He had a problem with data mismatch.As shown below:

Error in load.data(my.data) : Error with data: some data are not matched pairs.

I also looked at your scripts on github and found that the two sample sizes don't match up. But we're using rMATs to start with the bam file and he's able to compute p-values.

But I also checked the commands in your paired_model.R file and found that it was the same as the commands we ran. Why did yours have no errors and corresponding results while mine did not? Even though I filled 0 for it to make their sample numbers consistent, the final result was still different from that of rMATs.

So I take the liberty of writing to ask you. Sorry about that.

Here I first say thank you!

EricKutschera commented 8 months ago

The error you posted (some data are not matched pairs) is from: https://github.com/Xinglab/PAIRADISE/blob/master/pairadise/src/pairadise_model/R/load.data.r#L65

The error would happen if IJC_SAMPLE_1, SJC_SAMPLE_1, IJC_SAMPLE_2, and SJC_SAMPLE_2 are not all the same length.

From https://github.com/Xinglab/rmats-turbo/tree/v4.2.0#using-the-paired-stats-model

The --paired-stats flag can be used if each entry in --b1 is matched with its pair in --b2

You also said:

But we're using rMATs to start with the bam file and he's able to compute p-values

Did you run rMATS without --paired-stats? In that case rMATS does not require --b1 and --b2 to have the same number of files and that could explain how it was able to compute p-values