Massive univariate linear model.
Module with helpers functions.
-
mulm.helpers.
design_matrix
(formula, data)[source]ΒΆ Build the design matrix t-contrasts and F-contrasts given the formula and the dataframe. Remark: use patsy.dmatrix(formula, data=data)
- Parameters
formula, str
data, DataFrame
- Returns
X: array
the design matrix
t_contrasts: OrderedDict key=colname, val=array (P,)
remark: len(t_contrasts) == X.shape[1]
f_contrasts: OrderedDict key=term name in formula, val=array (P, P)
not documented.
Follow us
© 2021,
pylearn-mulm developers
.
Inspired by AZMIND template.
Inspired by AZMIND template.