From cf4f9f65465f55ab625703050f25859c0240aa0f Mon Sep 17 00:00:00 2001 From: Matteo Bachetti Date: Thu, 28 Sep 2023 22:29:42 +0200 Subject: [PATCH] Fix test of lomb-scargle periodogram with wrong comparison --- stingray/tests/test_lombscargle.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stingray/tests/test_lombscargle.py b/stingray/tests/test_lombscargle.py index d352f7076..4a8f76f5e 100644 --- a/stingray/tests/test_lombscargle.py +++ b/stingray/tests/test_lombscargle.py @@ -59,7 +59,7 @@ def test_eventlist(self): ev_lscs = LombScargleCrossspectrum(ev1, ev2, dt=1) lc_lscs = LombScargleCrossspectrum(lc1, lc2, dt=1) - assert np.argmax(lc_lscs) == np.argmax(ev_lscs) + assert np.argmax(lc_lscs.power) == np.argmax(ev_lscs.power) assert np.all(ev_lscs.freq == lc_lscs.freq) assert np.all(ev_lscs.power == lc_lscs.power) assert ev_lscs.freq[np.argmax(ev_lscs.power)] == lc_lscs.freq[np.argmax(lc_lscs.power)] != 0