Repository navigation
Closed
Description
The first test run that uses newly released scipy 0.8 has two new test failures in old code
======================================================================
FAIL: statsmodels.miscmodels.tests.test_tmodel.TestTModel.test_basic
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/statsmodels-0.8.0-py2.7-linux-x86_64.egg/statsmodels/miscmodels/tests/test_tmodel.py", line 86, in test_basic
assert_allclose(res1.params[-2], res2.dof, rtol=1e-5)
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/numpy/testing/utils.py", line 1395, in assert_allclose
verbose=verbose, header=header)
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/numpy/testing/utils.py", line 737, in assert_array_compare
raise AssertionError(msg)
AssertionError:
Not equal to tolerance rtol=1e-05, atol=0
(mismatch 100.0%)
x: array(2.837219360564396)
y: array(2.837183)
======================================================================
FAIL: statsmodels.tools.tests.test_rootfinding.test_brentq_expanding
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/statsmodels-0.8.0-py2.7-linux-x86_64.egg/statsmodels/tools/tests/test_rootfinding.py", line 84, in test_brentq_expanding
assert_equal(info1[k], info.__dict__[k])
File "/home/travis/miniconda2/envs/statsmodels-test/lib/python2.7/site-packages/numpy/testing/utils.py", line 379, in assert_equal
raise AssertionError(msg)
AssertionError:
Items are not equal:
ACTUAL: 63
DESIRED: 66
Activity
bashtage commentedon Jul 27, 2016
I hope you mean 0.18.
josef-pkt commentedon Jul 27, 2016
Yes, 0.18.0
conda switched to using it as the latest version. I guess there was no other upgrade at the same time.
I haven't looked yet but I guess at some changes in scipy.optimize.
bashtage commentedon Aug 5, 2016
From scipy:
josef-pkt commentedon Aug 9, 2016
nelder-mead had some changes to the termination criteria maxiter verses maxfval
another one I'm seeing now with scipy 0.18
https://travis-ci.org/statsmodels/statsmodels/jobs/151013680
My guess is that the B-matrix with opposite "matrix sign" is the same model, i.e. linear transformation of a symmetric distribution (normal) -x ~ x if x is symmetric/normal distributed
(not sure yet what to do: adjust test, check for scipy problems, or renormalize estimate)
josef-pkt commentedon Aug 9, 2016
maybe:
But SVAR doesn't have enough unit tests to change without checking the background.
josef-pkt commentedon Aug 9, 2016
I'm pretty sure the above is right. This corresponds to a standard deviation in the univariate case which could come out as negative in an optimization. variance or covariance matrix would be the same with either sign. The Stata documentation for SVAR doesn't mention anything about it.
-> adjust unit test to use abs for now, and leave proper solution for later when SVAR is fully supported.
Merge pull request statsmodels#3147 from josef-pkt/test_scipy08_3128