def filter_by_cols(self, cols, ID=None):
        """
        Keep only Measurements in corresponding columns.
        """
        rows = to_list(cols)
        fil = lambda x: x in rows
        applyto = {k: self._positions[k][1] for k in self.keys()}
        if ID is None:
            ID = self.ID + '.filtered_by_cols'
        return self.filter(fil, applyto=applyto, ID=ID)
Keep only Measurements in corresponding columns.