def summariseDEResults(self):
        ''' summarise DE results. Counts instances of possible outcomes'''

        # TS: the summarising is now split by the comparison being made and a
        # dict returned with keys=comparisons, value=E.Counter per comparison

        self.Summary = {}

        control_names = set(self.table['control_name'])
        treatment_names = set(self.table['treatment_name'])

        for control, treatment in itertools.product(control_names,
                                                    treatment_names):

            tmp_table = self.table[self.table['control_name'] == control]
            tmp_table = tmp_table[tmp_table['treatment_name'] == treatment]
            tmp_table.reset_index(inplace=True)

            # check control, treatment combination exists
            n_rows = tmp_table.shape[0]
            if n_rows > 0:

                if control != treatment:
                    label = control + "_" + treatment
                else:
                    label = control
                label = re.sub(":", "_int_", label)

                counts = E.Counter()

                counts.signficant = sum(tmp_table['significant'])
                counts.insignficant = (len(tmp_table['significant']) -
                                       counts.signficant)
                counts.all_over = sum([x > 0 for x in tmp_table['l2fold']])
                counts.all_under = sum([x < 0 for x in tmp_table['l2fold']])
                counts.signficant_over = sum(
                    [tmp_table['significant'][x] == 1 and
                     tmp_table['l2fold'][x] > 1 for x in range(0, n_rows)])
                counts.signficant_under = sum(
                    [tmp_table['significant'][x] == 1 and
                     tmp_table['l2fold'][x] < 1 for x in range(0, n_rows)])

                self.Summary[label] = counts
dataset/ETHPy150Open CGATOxford/cgat/CGAT/Expression.py/DEResult.summariseDEResults/original