If the sample size is small (or the number of bootstraps is large), the correlation coefficients can be undefined and return nan values. The use of np.percentile() then returns nan from pymccorrelation(). If there's many nan values this probably suggests the bootstrapping is not well-converged. When looking at the mock dataset to check recovery (#4), the convergence of bootstrapping would be good to consider.
Ultimately, decide if nanpercentile() should be used, optionally with a warning if the size of the dataset is too small for reliable bootstrap error estimation.
There is probably statistics literature about this too...
If the sample size is small (or the number of bootstraps is large), the correlation coefficients can be undefined and return
nanvalues. The use ofnp.percentile()then returns nan frompymccorrelation(). If there's manynanvalues this probably suggests the bootstrapping is not well-converged. When looking at the mock dataset to check recovery (#4), the convergence of bootstrapping would be good to consider.Ultimately, decide if
nanpercentile()should be used, optionally with a warning if the size of the dataset is too small for reliable bootstrap error estimation.There is probably statistics literature about this too...