diff --git a/pyfstat/core.py b/pyfstat/core.py index aceda60351219f7560392e62f35193337516a508..a4784bf8043430d345a35f2ae10ad7e9dfd3a8c1 100755 --- a/pyfstat/core.py +++ b/pyfstat/core.py @@ -440,7 +440,11 @@ class ComputeFstat(object): self.FstatResults.multiFatoms[0], self.windowRange, False) if self.BSGL is False: - return 2*FS.F_mn.data[0][0] + twoF = 2*FS.F_mn.data[0][0] + if np.isnan(twoF): + return 0 + else: + return twoF FstatResults_single = copy.copy(self.FstatResults) FstatResults_single.lenth = 1