0

I tried using qvalue function to calculate TPR:

library(qvalue)
qval_obj=qvalue(pvalR)
pi1=1-qval_obj$pi0

but after running:

qval_obj=qvalue(pvalR)
Error in smooth.spline(lambda, pi0, df = smooth.df) : 
  missing or infinite values in inputs are not allowed

or

 qval_obj=qvalue(pvalR,lambda=0.5)
Error in pi0est(p, ...) : 
  ERROR: The estimated pi0 <= 0. Check that you have valid p-values or use a different range of lambda.

I checked:

max(pvalR)
[1] 0.000352731
min(pvalR)
[1] 1.84872e-127
> sum(is.na(pvalR))
[1] 0
> sum(is.infinite(pvalR))
[1] 0
> length(pvalR)
[1] 129368

Also I tried using this flag: lambda=0 But:

> qval_objR=qvalue(pvalR,lambda=0)
> pi1=1-qval_objR$pi0
> pi1
[1] 0

Please advise,

Thanks Ana

user2458189
  • 93
  • 16
  • It's easier to help you if you include a simple [reproducible example](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example) with sample input and desired output that can be used to test and verify possible solutions. – MrFlick Sep 24 '19 at 16:04
  • Hi MrFlick I understand that but I am not sure how to reproduce it because it seems that the issue is with p values distribution... – user2458189 Sep 24 '19 at 16:11

0 Answers0