@staticmethod
    def apply_filters(df, filters):
        idx = pd.Series([True]*df.shape[0])
        for k, v in list(filters.items()):
            if k not in df.columns:
                continue
            idx &= (df[k] == v)

        return df.loc[idx]
Basic filtering for a dataframe.
dataset/ETHPy150Open stitchfix/pyxley/pyxley/charts/charts.py/Chart.apply_filters