

def test_issue_339():
    data = sm.datasets.anes96.load()
    exog = data.exog
    exog = exog[:, :(- 1)]
    exog = sm.add_constant(exog, prepend=True)
    res1 = sm.MNLogit(data.endog, exog).fit(method='newton', disp=0)
    smry = '\n'.join(res1.summary().as_text().split('\n')[9:])
    cur_dir = os.path.dirname(os.path.abspath(__file__))
    test_case_file = os.path.join(cur_dir, 'results', 'mn_logit_summary.txt')
    test_case = open(test_case_file, 'r').read()
    np.testing.assert_equal(smry, test_case[:(- 1)])

dataset/ETHPy150Open statsmodels/statsmodels/statsmodels/discrete/tests/test_discrete.py test_issue_339/original