def __init__(self):
        from statsmodels.datasets.cpunish import load_pandas
        self.data = load_pandas()
        self.endog = self.data.endog
        self.exog = self.data.exog[['INCOME', 'SOUTH']]
        np.random.seed(1234)
        self.weight = np.random.randint(5, 100, len(self.endog))
        self.endog_big = np.repeat(self.endog.values, self.weight)
        self.exog_big = np.repeat(self.exog.values, self.weight, axis=0)
        link = sm.families.links.Power
        family_link = sm.families.Tweedie(var_power=2, link_power=1, link=link)
        self.res1 = GLM(self.endog, self.exog,
                        freq_weights=self.weight,
                        family=family_link).fit()
        self.res2 = GLM(self.endog_big, self.exog_big,
                        family=family_link).fit()
Tests Gamma family with log link.
dataset/ETHPy150Open statsmodels/statsmodels/statsmodels/genmod/tests/test_glm.py/TestWtdTweediePower2.__init__