#NEWLINE# def test_stratified_table_cube( ) : #NEWLINE# #INDENT# '\n    Test that we can pass a rank 3 ndarray or a list of rank 2\n    ndarrays to StratifiedTable and get the same results.\n    ' #NEWLINE# tab1 = [ [ [ 8 , 9 ] , [ 6 , 7 ] ] , [ [ 4 , 9 ] , [ 5 , 5 ] ] , [ [ 8 , 8 ] , [ 9 , 11 ] ] ] #NEWLINE# tab2 = np . asarray ( tab1 ) . T #NEWLINE# ct1 = ctab . StratifiedTable ( tab1 ) #NEWLINE# ct2 = ctab . StratifiedTable ( tab2 ) #NEWLINE# assert_allclose ( ct1 . oddsratio_pooled , ct2 . oddsratio_pooled ) #NEWLINE# assert_allclose ( ct1 . logodds_pooled , ct2 . logodds_pooled )