def getTraitCovar(self, term_i=None):
        """
        Return the estimated trait covariance matrix for term_i (or the total if term_i is None)
            To retrieve the matrix of correlation coefficient use \see getTraitCorrCoef

        Args:
            term_i:     index of the random effect term we want to retrieve the covariance matrix
        Returns:
            estimated trait covariance 
        """
        assert term_i < self.n_randEffs, 'VarianceDecomposition:: specied term out of range'

        if term_i is None:
            RV = sp.zeros((self.P,self.P))
            for term_i in range(self.n_randEffs):
                RV += self.getTraitCovarFun().K()
        else:
            assert term_i<self.n_randEffs, 'Term index non valid'
            RV = self.getTraitCovarFun(term_i).K()
        return RV