def loglike(self, params):

        q = 2*self.endog - 1
        X = self.exog
        return np.sum(np.log(np.clip(self.cdf(q*np.dot(X,params)),
            FLOAT_EPS, 1)))
Pre and post order traversal of the tree
dataset/ETHPy150Open statsmodels/statsmodels/statsmodels/discrete/discrete_model.py/Probit.loglike--crossover with--dataset/ETHPy150Open biocore/scikit-bio/skbio/tree/tests/test_tree.py/TreeTests.test_pre_and_postorder