def generate_table(self, col, **kwargs): table = E.table(**kwargs) for attr, value in col: table.append(E.tr(E.td(value, **attr))) return table