Exemplo n.º 1
0
    def test_coherence_fails_if_data2_not_lc(self):
        data = np.array([[1,2,3,4,5],[2,3,4,5,1]])

        with pytest.raises(TypeError):
            coh = coherence(data, self.lc2)
Exemplo n.º 2
0
    def test_coherence_computes_correctly(self):

        coh = coherence(self.lc1, self.lc2)

        assert len(coh) == 2
        assert np.abs(np.mean(coh)) < 1
Exemplo n.º 3
0
    def test_coherence_computes_correctly(self):
        with pytest.warns(UserWarning) as record:
            coh = coherence(self.lc1, self.lc2)

        assert len(coh) == 2
        assert np.abs(np.mean(coh)) < 1
Exemplo n.º 4
0
 def test_coherence_runs(self):
     coh = coherence(self.lc1, self.lc2)
Exemplo n.º 5
0
 def test_coherence_runs(self):
     with pytest.warns(UserWarning) as record:
         coh = coherence(self.lc1, self.lc2)
Exemplo n.º 6
0
    def test_coherence_computes_correctly(self):

        coh = coherence(self.lc1, self.lc2)

        assert len(coh) == 2
        assert np.abs(np.mean(coh)) < 1
Exemplo n.º 7
0
    def test_coherence_fails_if_data2_not_lc(self):
        data = np.array([[1,2,3,4,5],[2,3,4,5,1]])

        with pytest.raises(AssertionError):
            coh = coherence(data, self.lc2)
Exemplo n.º 8
0
 def test_coherence_runs(self):
     coh = coherence(self.lc1, self.lc2)
Exemplo n.º 9
0
    def test_coherence_fails_if_data1_not_lc(self):
        data = np.array([[1,2,3,4,5],[2,3,4,5,1]])

        with pytest.raises(TypeError):
            coh = coherence(self.lc1, data)