Beispiel #1
0
def test_filter_threshold_lots():
    cors = {'f1': 0.2, 'f2': 0.3, 'f3': 0.7, 'f4': 0.95}
    expected_result = {
        'f2': 0.3, 'f3': 0.7, 'f4': 0.95
    }
    result = coach.filter_threshold(cors, 0.21)
    eq_(result, expected_result)
Beispiel #2
0
def test_filter_threshold_equal():
    '''Ensure filter_threshold doesn't reject correlations when they are
    on the threshold.'''
    cors = {'f1': 0.2, 'f2': 0.3, 'f3': 0.7, 'f4': 0.95}
    expected_result = {
        'f4': 0.95,
    }
    result = coach.filter_threshold(cors, 0.95)
    eq_(result, expected_result)