def _expand_vcomp(self, vcomp, group):
        if len(vcomp) == 0:
            return np.empty(0)
        vc_var = []
        for j, k in enumerate(self._vc_names):
            if group in self.exog_vc[k]:
                vc_var.append(vcomp[j] * np.ones(self.exog_vc[k][group].shape[1]))
        if len(vc_var) > 0:
            return np.concatenate(vc_var)
        else:
            1/0
            return np.empty(0)
Replicate variance parameters to match a group's design.
dataset/ETHPy150Open statsmodels/statsmodels/statsmodels/regression/mixed_linear_model.py/MixedLM._expand_vcomp