
    M/Ph@p              
          d Z ddlmZ ddlZd Zd Zd Zd4dZd4d	Z	d5d
Z
d6dZd7dZd Zd7dZ G d d          Zd Z G d d          Z G d d          Zedk    r e            Ze                                 e                                 e                                 ddlmZ g dd         Zg dZddgZ e
ee          Z ee            ej         d          Z! ej         d          dz  Z" ej         d          dz  dz  Z#d ev r ee"          \  Z$Z% ee#          \  Z&Z'd!ev r& ej(        e"d"d#          Z" ej(        e#d"d#          Z#e"j)        d         Z* ee"          \  Z$Z% ee#          \  Z&Z' ee$e&d$          Z+ ee$e&d%$          Z, ee$e&d&$          Z- e ej.        e+j/        e+           ej0        e+1                    d                    k    2                                           d'd(gd         Z3d)d*gd         Z4e4ej5        6                    e*          z  Z7e3 ej         dd+          z  Z8e+e8z  1                    d          e7z   Z9e,e8z  1                    d          e7z   Z:e-e8z  1                    d          e7z   Z; ej<        e9e+          =                                Z> ej<        e9e-          =                                Z?e>j@        ZAe?j@        ZB ej<        e;e+          =                                ZC ej<        e;e-          =                                ZDeCj@        ZEeDj@        ZFejG        H                    e-e+d,-          d         ZIejG        H                    e+e-d,-          d         ZJ e ej.        eJeF          eEz
              e ej.        eIeA          eBz
              ee+e-          ZK e ejL         ejM        e+eKN                    e-          z
                                  e ejL         ejM        e-eKO                    e+          z
                                  e ejL         ejM        eFeKP                    eE          z
                                  ejL         ejM        eBeKP                    eA          z
                        e
ee          \  ZQZRZSZTZUZV ed.            ed/            eeS            eeCW                    eR          jX                    ed0            ed1            eeU            eeCW                    eT          jX                   eCY                    eT            ejZ         ej[        d2           ej\        d          f          Z]e?j^        d3d         Z_e>W                    eKN                    e]                    jX        Z` e ejL         ejM        e_e`z
                                  ee;e"e#          Za eeab                                jX                    eeab                                jc                    eead                                je                    eead                                jc                    eeaf                    d          d         jX                    eeaf                    d          d         jX                    eeag                                           	 dS )8a  functions to work with contrasts for multiple tests

contrast matrices for comparing all pairs, all levels to reference level, ...
extension to 2-way groups in progress

TwoWay: class for bringing two-way analysis together and try out
various helper functions


Idea for second part
- get all transformation matrices to move in between different full rank
  parameterizations
- standardize to one parameterization to get all interesting effects.

- multivariate normal distribution
  - exploit or expand what we have in LikelihoodResults, cov_params, f_test,
    t_test, example: resols_dropf_full.cov_params(C2)
  - connect to new multiple comparison for contrast matrices, based on
    multivariate normal or t distribution (Hothorn, Bretz, Westfall)

    )assert_equalNc                     g }t          |           D ]K}t          |dz   |           D ]5}t          j        |           }d||<   d||<   |                    |           6Lt          j        |          S )zcontrast or restriction matrix for all pairs of nm variables

    Parameters
    ----------
    nm : int

    Returns
    -------
    contr : ndarray, 2d, (nm*(nm-1)/2, nm)
       contrast matrix for all pairwise comparisons

       )rangenpzerosappendarray)nmcontrij	contr_rows        h/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/statsmodels/sandbox/stats/contrast_tools.pycontrast_allpairsr      s     E2YY $ $qsB 	$ 	$AIIaLIaLLL####		$
 8E??    c                     t          j        t          j        | dz
            t          j        | dz
             f          }|S )zcontrast or restriction matrix for all against first comparison

    Parameters
    ----------
    nm : int

    Returns
    -------
    contr : ndarray, 2d, (nm-1, nm)
       contrast matrix for all against first comparisons

    r   )r   column_stackoneseye)r   r   s     r   contrast_all_oner   5   s7     ORWRT]]RVBqD\\M:;;ELr   c                 ^    t          j        |           t          j        | | f          | z  z
  S )zcontrast or restriction matrix for all against mean comparison

    Parameters
    ----------
    nm : int

    Returns
    -------
    contr : ndarray, 2d, (nm-1, nm)
       contrast matrix for all against mean comparisons

    )r   r   r   )r   s    r   contrast_diff_meanr   E   s*     6"::B((+++r   Fc                     | dv r:|st          j        |           dk    rdndS t          j        |           dk    rdndS t          |           S )N)r   r   r   r   +- )r   signstr)xnopluss     r   signstrr#   T   sR    H}} 	0'!**a--33S0Q22C/1vvr   c                 n    |rt          d d d          nt          d           fd| D             }|S )Nr   c           	      v    g | ]5}d                      d t          |                   D                       6S )r   c                 J    g | ] \  }}|d k    t          |d           | !S r   T)r"   r#   .0cvs      r   
<listcomp>z.contrast_labels.<locals>.<listcomp>.<listcomp>c   sG     D D D!aAFF "!D1116166<BFFr   joinzip)r*   rownamessls     r   r-   z#contrast_labels.<locals>.<listcomp>c   sg     3 3 3!$ gg D D%(e__R%8D D D E E 3 3 3r   )slice)	contrastsr2   reverselabelsr3   s    `  @r   contrast_labelsr8   ^   s^     4r""4[[3 3 3 3 3(13 3 3F Mr   c                    t          |           }t                    }fd| D             t          j        d|f          }d|d<   |s#t          j        |t	          |           f         }n"t          j        |t          |           f         }t          j        |dd         t          j        |                    }	t          |	d          }
fd|	D             }t          j        d|f          }d|d<   |s#t          j        |t	          |           f         }n"t          j        |t          |           f         }t          j        t          j        |          |dd                   }fd|D             }|7|5t          |          \  }}t          |          \  }}t          ||          }nd}|	||||fS )	a  build contrast matrices for products of two categorical variables

    this is an experimental script and should be converted to a class

    Parameters
    ----------
    names1, names2 : lists of strings
        contains the list of level labels for each categorical variable
    intgroup1, intgroup2 : ndarrays     TODO: this part not tested, finished yet
        categorical variable


    Notes
    -----
    This creates a full rank matrix. It does not do all pairwise comparisons,
    parameterization is using contrast_all_one to get differences with first
    level.

    ? does contrast_all_pairs work as a plugin to get all pairs ?

    c                 (    g | ]}D ]	}| d | 
S )_ )r*   r   r   names2s      r   r-   z$contrast_product.<locals>.<listcomp>   s0    ===f==Q****====r   r   )r   r   NT)r6   c           	      |    g | ]8}d                      d t          |          ddd         D                       9S )r   c                 J    g | ] \  }}|d k    t          |d           | !S r'   r(   r)   s      r   r-   z/contrast_product.<locals>.<listcomp>.<listcomp>   sG     $O $O $O"%!AqAvv (/q'>'>'>$C$C$CGMvvr   Nr   r.   r*   r1   
names_prods     r   r-   z$contrast_product.<locals>.<listcomp>   so     ; ; ;%( 77 $O $O),S*)=)=ddd)C$O $O $O P P ; ; ;r   c           	      |    g | ]8}d                      d t          |          ddd         D                       9S )r   c                 J    g | ] \  }}|d k    t          |d           | !S r'   r(   r)   s      r   r-   z/contrast_product.<locals>.<listcomp>.<listcomp>   sG     %O %O %O"%!AqAvv )0$(?(?(?%D%D%DGMvvr   Nr   r.   r@   s     r   r-   z$contrast_product.<locals>.<listcomp>   so     < < <%( GG %O %O),S*)=)=ddd)C%O %O %O P P < < <r   )lenr   r	   r_r   r   kronr   r8   dummy_1ddummy_product)names1r=   	intgroup1	intgroup2pairsn1n2ee1ddcontrast_prodnames_contrast_prod0names_contrast_prodee2dd2contrast_prod2names_contrast_prod2d1r;   d2dummyrA   s    `                  @r   contrast_productr[   h   s   . 
VB	VB====f===J
(Ab6

CCH 0U3)"----.U3*2..../GBqrrFBF2JJ//M*=*dSSS; ; ; ;,9; ; ; (Ab6

CCH 1eC*2..../eC+B////0WRVBZZQRR11N< < < <,:< < < 	I$9##A##Ab"%%':&(<eE Er   c                    d t          |                                 dz             D             }| dddf         t          j        |                                 dz             k                        t
                    |fS t          j        |           }fd|D             }| dddf         |k                        t
                    |fS )a  dummy variable for id integer groups

    Parameters
    ----------
    x : ndarray, 1d
        categorical variable, requires integers if varname is None
    varname : str
        name of the variable used in labels for category levels

    Returns
    -------
    dummy : ndarray, 2d
        array of dummy variables, one column for each level of the
        category (full set)
    labels : list[str]
        labels for the columns, i.e. levels of each category


    Notes
    -----
    use tools.categorical instead for more more options

    See Also
    --------
    statsmodels.tools.categorical

    Examples
    --------
    >>> x = np.array(['F', 'F', 'M', 'M', 'F', 'F', 'M', 'M', 'F', 'F', 'M', 'M'],
          dtype='|S1')
    >>> dummy_1d(x, varname='gender')
    (array([[1, 0],
           [1, 0],
           [0, 1],
           [0, 1],
           [1, 0],
           [1, 0],
           [0, 1],
           [0, 1],
           [1, 0],
           [1, 0],
           [0, 1],
           [0, 1]]), ['gender_F', 'gender_M'])

    Nc                     g | ]}d |z  S )zlevel_%dr<   )r*   r   s     r   r-   zdummy_1d.<locals>.<listcomp>   s    ===Q*q.===r   r   c                 :    g | ]}d t          |          z  z   S )z_%s)r    )r*   r   varnames     r   r-   zdummy_1d.<locals>.<listcomp>   s(    @@@q'ECFFN*@@@r   )r   maxr   arangeastypeintunique)r!   r_   r7   grouplabelss    `  r   rG   rG      s    \ ==%!*<*<===!!!D&	29QUUWWQY///77<<fDDill@@@@K@@@!!!D&	;&..s33V;;r   fullc                    |dk    r@| dddddf         |dddddf         z                       | j        d         d          }n|dk    r|t          | ddddf         |ddddf                   }t          j        t          j        | j        d         t                    | ddddf         |ddddf         |f          }n|dk    r|t          | ddddf         |ddddf                   }t          j        t          j        | j        d         t                    | ddddf         |ddddf         |f          }nt          d          |S )	a  dummy variable from product of two dummy variables

    Parameters
    ----------
    d1, d2 : ndarray
        two dummy variables, assumes full set for methods 'drop-last'
        and 'drop-first'
    method : {'full', 'drop-last', 'drop-first'}
        'full' returns the full product, encoding of intersection of
        categories.
        The drop methods provide a difference dummy encoding:
        (constant, main effects, interaction effects). The first or last columns
        of the dummy variable (i.e. levels) are dropped to get full rank
        dummy matrix.

    Returns
    -------
    dummy : ndarray
        dummy variable for product, see method

    rf   Nr   r   	drop-last
drop-firstr   method not recognized)reshapeshaperH   r   r   r   rc   
ValueError)rX   rY   methodrP   d12rld12rs         r   rH   rH      su   . 111Tl2aaaQQQh<'00!R@@	;		b3B3iAAAcrcE33_bgbhqk377AAAcrcEBqqq"uIeTUU	<		R!""Xr!!!ABB$x00_bgbhqk377AAAabbD2aaad8DQRR0111Ir   c                 2   | j         \  }}t          j        t          j        | d          dk              \  }}t          j        t          j        | d          dk              \  }}t          j        |          }t          j        dg|f         |k                                    r.t          j        ||dz
  gf         |k                                    st          d          t          j        dg|dz   f         }t          j        |dz   |gf         }	||	fS )a  start and endpoints of groups in a sorted dummy variable array

    helper function for nested categories

    Examples
    --------
    >>> d1 = np.array([[1, 0, 0],
                       [1, 0, 0],
                       [1, 0, 0],
                       [1, 0, 0],
                       [0, 1, 0],
                       [0, 1, 0],
                       [0, 1, 0],
                       [0, 1, 0],
                       [0, 0, 1],
                       [0, 0, 1],
                       [0, 0, 1],
                       [0, 0, 1]])
    >>> dummy_limits(d1)
    (array([0, 4, 8]), array([ 4,  8, 12]))

    get group slices from an array

    >>> [np.arange(d1.shape[0])[b:e] for b,e in zip(*dummy_limits(d1))]
    [array([0, 1, 2, 3]), array([4, 5, 6, 7]), array([ 8,  9, 10, 11])]
    >>> [np.arange(d1.shape[0])[b:e] for b,e in zip(*dummy_limits(d1))]
    [array([0, 1, 2, 3]), array([4, 5, 6, 7]), array([ 8,  9, 10, 11])]
    r   axisr   r   zdummy variable is not sorted)rl   r   nonzerodiffra   rE   allrm   )
dnobsnvarsstart1col1end1col1_ccstartends
             r   dummy_limitsr     s   : 'KD%:bgaQ///233LFD*RWQA...233KD%	5		BeQCI"$))++ 9U557)+,2779997888E1#vax- E
%Q
C#:r   c                    |dk    r|S t          |           \  }}t          |          \  }}t          j        ||          }t          j        ||          }||k    }	| |	 z  }
| |	 z  }|dk    ryt          | ddddf         |ddddf                   }t          j        t          j        | j        d         t                    | ddddf         |dd|f         f          }n|dk    ryt          | ddddf         |ddddf                   }t          j        t          j        | j        d         t                    | ddddf         |dd|
f         f          }nt          d          ||
|fS )	a  unfinished and incomplete mainly copy past dummy_product
    dummy variable from product of two dummy variables

    Parameters
    ----------
    d1, d2 : ndarray
        two dummy variables, d2 is assumed to be nested in d1
        Assumes full set for methods 'drop-last' and 'drop-first'.
    method : {'full', 'drop-last', 'drop-first'}
        'full' returns the full product, which in this case is d2.
        The drop methods provide an effects encoding:
        (constant, main effects, subgroup effects). The first or last columns
        of the dummy variable (i.e. levels) are dropped to get full rank
        encoding.

    Returns
    -------
    dummy : ndarray
        dummy variable for product, see method

    rf   rh   Nr   r   ri   r   rj   )	r   r   in1drH   r   r   rl   rc   rm   )rX   rY   rn   rz   r|   start2end2firstlastequal	col_dropf	col_droplro   rP   rp   s                  r   dummy_nestedr   2  s   , 	##LFD##LFDGFF##E74Dd]EvIufI b3B3iAAAcrcE33_bgbhqk377AAAcrcEBqqq{OTUU	<		R!""Xr!!!ABB$x00_bgbhqk377AAAabbD2aaa	k?STT0111y)##r   c                   0    e Zd ZdZd Zd Zd Zd Zd ZdS )DummyTransforma  Conversion between full rank dummy encodings


    y = X b + u
    b = C a
    a = C^{-1} b

    y = X C a + u

    define Z = X C, then

    y = Z a + u

    contrasts:

    R_b b = r

    R_a a = R_b C a = r

    where R_a = R_b C

    Here C is the transform matrix, with dot_left and dot_right as the main
    methods, and the same for the inverse transform matrix, C^{-1}

    Note:
     - The class was mainly written to keep left and right straight.
     - No checking is done.
     - not sure yet if method names make sense


    c                     t           j                            ||d          d         | _        t           j                            ||d          d         | _        dS )z\C such that d1 C = d2, with d1 = X, d2 = Z

        should be (x, z) in arguments ?
        r   rcondr   N)r   linalglstsqtransf_matrixinvtransf_matrix)selfrX   rY   s      r   __init__zDummyTransform.__init__  sL    
  Y__R2_>>qA "	Bb A A! Dr   c                 6    t          j        | j        |          S )z b = C a
        r   dotr   )r   as     r   dot_leftzDummyTransform.dot_left  s     vd(!,,,r   c                 6    t          j        || j                  S )z z = x C
        r   )r   r!   s     r   	dot_rightzDummyTransform.dot_right  s     va+,,,r   c                 6    t          j        | j        |          S )z a = C^{-1} b
        r   r   r   )r   bs     r   inv_dot_leftzDummyTransform.inv_dot_left  s     vd+Q///r   c                 6    t          j        || j                  S )z x = z C^{-1}
        r   )r   zs     r   inv_dot_rightzDummyTransform.inv_dot_right  s     va.///r   N)	__name__
__module____qualname____doc__r   r   r   r   r   r<   r   r   r   r   a  sm         @E E E- - -
- - -
0 0 0
0 0 0 0 0r   r   c                    t          j        |           } | j        dz   }t          d          gdg|dz
  z  z   t          d          gz   }| d         ||         z                      d          dz  |                    d          z  S )an  groupmeans using dummy variables

    Parameters
    ----------
    x : array_like, ndim
        data array, tested for 1,2 and 3 dimensions
    d : ndarray, 1d
        dummy variable, needs to have the same length
        as x in axis 0.

    Returns
    -------
    groupmeans : ndarray, ndim-1
        means for each group along axis 0, the levels
        of the groups are the last axis

    Notes
    -----
    This will be memory intensive if there are many levels
    in the categorical variable, i.e. many columns in the
    dummy variable. In this case it is recommended to use
    a more efficient version.

    r   N   ).Nr         ?)r   asarrayndimr4   sum)r!   rw   ry   slis       r   groupmean_dr     s}    2 	
1A FQJE;;-4&%'*
*eDkk]
:ChK!C& %%a((+AEE!HH44r   c                   8    e Zd ZdZd	dZd Zd Zd Zd Zd Z	dS )
TwoWaya  a wrapper class for two way anova type of analysis with OLS


    currently mainly to bring things together

    Notes
    -----
    unclear: adding multiple test might assume block design or orthogonality

    This estimates the full dummy version with OLS.
    The drop first dummy representation can be recovered through the
    transform method.

    TODO: add more methods, tests, pairwise, multiple, marginal effects
    try out what can be added for userfriendly access.

    missing: ANOVA table

    Nc                 D   |j         d         | _        |d}d}n|\  }}t          ||          x\  | _        | _        \  }}t          ||          x\  | _        | _        \  }	}
|j         d         x| _        }|	j         d         x| _        }t          ||
          }|\  }}}}}}|\  | _
        | _        | _        | _        | _        }t          ||	d          }t          ||	d          }t!          ||          | _        |j         d         | _        || _        t)          j        ||                                          | _        | j        j        | _        | j                            | j                  | _        d|dz
  z   |dz
  z   | _        | j        | j        z
  | _        d S )Nr   r   r   r   rf   rn   ri   )rl   rx   rG   rX   	d1_labelsrY   	d2_labelsnlevel1nlevel2r[   
prod_labelC1C1_labelC2C2_labelrH   r   	transformry   exogsmOLSfitresolsparamsr   params_dropfstart_interactionn_interaction)r   endogfactor1factor2varnamesvname1vname2rX   r   rY   r   r   r   resprodlabr   C1labr   C2labr;   dp_fulldp_dropfs                         r   r   zTwoWay.__init__  s   M!$	FFF%NFF2:7F2K2KK-"i2:7F2K2KK-"i!#!,w!#!,w y)44+.(UBqMPJ$-$-Bv666 R===':: ]1%
	fUG,,0022k( !N77DD!"gk!2gk!B!Z$*@@r   c                     | j         }t          j        t          j        || j        |z
  f          t          j        |          f          }| j                            |          }|| _        |S )z7contrast/restriction matrix for no interaction
        )	r   r   hstackr	   ry   r   r   r   R_nointer_transf)r   nia	R_nointerr   s       r   	r_nointerzTwoWay.r_nointer  sa      Irxdjn(=>>sLMM	>77	BB 0r   c                    | j         }t          j        t          j        || j        |z
  f          t          j        |          f          }| j                            |          }|| _        | j	        
                    |          }|S z1ttests for no-interaction terms are zero
        )r   r   r   r	   ry   r   r   r   r   r   t_test)r   r   r   r   t_ress        r   ttest_interactionzTwoWay.ttest_interaction  sv      Irxdjn(=>>sLMM	>77	BB 0""#344r   c                 ^    |                                  }| j                            |          S r   )r   r   f_test)r   r   s     r   ftest_interactionzTwoWay.ftest_interaction  s+      >>++{!!"2333r   c                     |dk    r&| j                             | j                  | j        fS | j                             | j                  | j        fS )Nr   )r   r   r   r   r   r   )r   	factorinds     r   ttest_conditional_effectzTwoWay.ttest_conditional_effect  sI    >>;%%dg..==;%%dg..==r   c                     ddl m} | j                            | j        | j                  }| j        }| j        }d}t          dg| j        z            } ||||||          S )Nr   )SimpleTablez!Estimated Coefficients by factorsz%#10.4g)	data_fmts)titletxt_fmt)	statsmodels.iolibr   r   rk   r   r   r   r   dict)r   r   
params_arrstubsheadersr   	table_fmts          r   summary_coeffzTwoWay.summary_coeff  s    111111[((t|DD
.3"DL02 2 2	{:wU#,. . . 	.r   N)
r   r   r   r   r   r   r   r   r   r   r<   r   r   r   r     s         &A A A AD     
 
 
4 4 4> > >	. 	. 	. 	. 	.r   r   c                   &    e Zd Zd Zd Zd Zd ZdS )TestContrastToolsc                     g d| _         ddg| _        t          j        g dg dg dg dg dg dg dg dg dg dg dg dg          | _        d S )Na0a1a2b0b1)r   r   r   )r   r   r   )r   r   r   )v1namev2namer   r   rX   )r   s    r   r   zTestContrastTools.__init__.  s    (((Tl(III%II%II%II%II%II%II%II%II%II%II%II' ( (r   c                    t          j        g dd          }t          j        ddgddgddgddgddgddgddgddgddgddgddgddgg          ddg}}t          |d	          \  }}t          ||           t          ||           d S )
N)Fr   Mr   r   r   r   r   r   r   r   r   z|S1)dtyper   r   gender_Fgender_Mgender)r_   )r   r   rG   r   )r   r!   rw   r7   res_d
res_labelss         r   test_dummy_1dzTestContrastTools.test_dummy_1d>  s    HQQQ  X1v !1v !1v !1v !1v !1v !1v !1v !1v !1v !1v !1v' ( ( +5j)A  %Q999zUAZ(((((r   c                    t          | j        | j                  }dgdz  }g d|d<   t          j        g dg dg dg dg          |d<   g d	|d
<   t          j        g dg dg dg          |d<   g d|d<   t          d          D ]=}t          j                            ||         ||         t          |                     >d S )Nr      )a0_b0a0_b1a1_b0a1_b1a2_b0a2_b1)              r   r  r  r  )r  r  r  r   r  r  )r  r  r  r  r   r  )r  r  r  r  r  r   r   )za1_b0-a0_b0za1_b1-a0_b1za2_b0-a0_b0za2_b1-a0_b1r   )r  r   r  r  r  r  )r  r  r  r   r  r  )r  r  r  r  r  r      )za0_b1-a0_b0za1_b1-a1_b0za2_b1-a2_b0      )err_msg)	r[   r   r   r   r   r   testingr   r    )r   res_cpres_tiis       r   test_contrast_productz'TestContrastTools.test_contrast_productQ  s   !$+t{;;AIIIa8;;;999999999; < <a POOaH<<<999999; < <a A@@a(( 	L 	LBJ##F2Jb	3r77#KKKK	L 	Lr   c                     t          | j                  \  }}t          |t          j        g d                     t          |t          j        g d                     d S )N)r   r     )r  r     )r   rX   r   r   r   )r   r   es      r   test_dummy_limitsz#TestContrastTools.test_dummy_limitsa  sW    47##!Q++,,,Q../////r   N)r   r   r   r   r  r  r  r<   r   r   r   r   ,  sS        ( ( ( ) ) )&L L L 0 0 0 0 0r   r   __main__)smalllargeNr   r   r   r   r  r  r   r   r!  r  rr   r   rh   ri   r   g{Gz?gMbP?g?   r   r   z"
tvalues for no effect of factor 1z/each test is conditional on a level of factor 2z"
tvalues for no effect of factor 2z/each test is conditional on a level of factor 1)r   r  )F)NNFr   )rf   )hr   numpy.testingr   numpyr   r   r   r   r#   r8   r[   rG   rH   r   r   r   r   r   r   r   ttr  r  r  statsmodels.apiapir   examplesr   r   r  printra   yx1x2rX   r   rY   r   repeatrl   rx   dd_fulldd_dropldd_dropfr   Tdiagr   rv   effect_sizenoise_scalerandomrandnnoisebeta
ydata_fullydata_droplydata_dropfr   r   resols_full_fullresols_full_dropfr   
params_f_fparams_f_dfresols_dropf_fullresols_dropf_dropfparams_df_fparams_df_dfr   r   tr_oftr_fotransf_f_dfr`   absr   r   r   r   r   r   r   r   r;   r   tvalue
cov_paramsr   r	   r   R_nointtvaluesinter_directinter_transftwr   pvaluer   fvaluer   r   r<   r   r   <module>rR     s   0 ' & & & & &      ,   , , ,      <E <E <E <ED4< 4< 4< 4<n# # # #J( ( (X,$ ,$ ,$ ,$^;0 ;0 ;0 ;0 ;0 ;0 ;0 ;0B5 5 5Fa. a. a. a. a. a. a. a.N80 80 80 80 80 80 80 80z z				B      '''*HFD\Fff--F	E&MMM	"A	2	B	2	A	B( I I (RYr11%%%RYr11%%%8A;DHRLLMB	HRLLMB	mB6222G}RK888H}RL999H 
E626')W%%Q)@)@@
E
E
G
GHHH
 t*Q-K#,q/K")//$///E1Q'DD.%%a((50Jd?''**U2Kd?''**U2Krvj'226688z84488::!(J#*K{G4488::X66::<<#*K%,L IOOHgRO88;EIOOGXRO88;E	E&"&
%
%
3444	E&"&

#
#k
1222 .(33K	E&"&+";";H"E"EEFF
G
GHHH	E&"&;#8#8#A#AABB
C
CDDD	E&"&&33K@@A B B C C D D D
BF626+&33J??@ A A B B B '7&6vv&F&F#GRE!	E
/000	E
;<<<	E%LLL	E

"
"2
&
&
-...	E
/000	E
;<<<	E%LLL	E

"
"2
&
&
-...   $$$ bi%&"&))455G$,RSS1L#**;+D+DW+M+MNNUL	E&"&|344
5
5666 
R	$	$B	E"


 
 
'(((	E"


 
 
'(((	E"


 
 
'(((	E"


 
 
'(((	E"
%
%a
(
(
+
2333	E"
%
%a
(
(
+
2333	E"



$GdJ Jr   