15b8e291b4f100036059013106d0a68dd6ddbf7b,mlxtend/classifier/tests/test_logistic_regression.py,,test_logistic_regression_gd,#,22

Before Change



    lr.fit(X, y)  // 0, 1 class
    np.testing.assert_almost_equal(lr.w_, t, 2)
    assert((y == lr.predict(X)).all())


def test_logistic_regression_sgd():
    t = np.array([0.53, 1.2, 4.4])

After Change



    lr.fit(X, y)  // 0, 1 class
    np.testing.assert_almost_equal(lr.w_, t, 2)
    y_pred = lr.predict(X)
    acc = np.sum(y == y_pred, axis=0) / float(X.shape[0])
    assert acc == 1.0, "Acc: %s" % acc


def test_logistic_regression_sgd():
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 12

Instances


Project Name: rasbt/mlxtend
Commit Name: 15b8e291b4f100036059013106d0a68dd6ddbf7b
Time: 2016-03-16
Author: mail@sebastianraschka.com
File Name: mlxtend/classifier/tests/test_logistic_regression.py
Class Name:
Method Name: test_logistic_regression_gd


Project Name: rasbt/mlxtend
Commit Name: 364625b410d7978ec6837d57d4057c9fc6afde88
Time: 2016-03-12
Author: mail@sebastianraschka.com
File Name: mlxtend/classifier/tests/test_logistic_regression.py
Class Name:
Method Name: test_logistic_regression_sgd


Project Name: rasbt/mlxtend
Commit Name: 364625b410d7978ec6837d57d4057c9fc6afde88
Time: 2016-03-12
Author: mail@sebastianraschka.com
File Name: mlxtend/classifier/tests/test_logistic_regression.py
Class Name:
Method Name: test_logistic_regression_gd


Project Name: rasbt/mlxtend
Commit Name: 15b8e291b4f100036059013106d0a68dd6ddbf7b
Time: 2016-03-16
Author: mail@sebastianraschka.com
File Name: mlxtend/classifier/tests/test_logistic_regression.py
Class Name:
Method Name: test_logistic_regression_sgd