Russel88/DOC

Discrepancies between Fns from plot and output of DOC function

Closed this issue · 2 comments

Hi,

I am working with your function to do analysis like those proposed in Nature paper. In some cases Matlab needs to much time and I found that in R it can be done faster.
My problem is that I want a different figure than default plot. I run the function with
DOC_out<-DOC(otus,R=100,cores=24) and get the default plot with plot(DOC_out), which is attached. In that plot the median Fns is over 0.95, but if I run median(DOC_out$FNS[,1]) I get 0.8722449. I used a set.seed(100) in my R session.
I think that it is my fault but I cannot see what I am doing wrong, because as you state in this web page the vertical line is the median Fns value from bootstraps.
Another question is: default settings (not R or the number of cores) are the "correct" to "mimic" the original function? And how I should get the P values of original matlab code?

Thank you very much,

Manuel

otus.zip
default_plot

Hi Manuel,

Yeah. I wrote this R code so that it would run faster than in Matlab.

It's actually a mistake I made in the README. The vertical line is not the median Fns, it's the median Overlap at which the fitted line has a negative slope.

The default should mimic the original script, except that, as I write in the README, the Fns values are from the bootstraps.