Does tabulator filtering update "selection" or any params?

I want to watch filter and use the filtered dataframe, but I don’t know what params it’s linked to

import pandas as pd
import panel as pn
pn.extension("tabulator")
pn.config.sizing_mode = "stretch_both"

mixed_df = pd.util.testing.makeMixedDataFrame()
filter_table = pn.widgets.Tabulator(mixed_df, width=1000, height=500)

filter_table.add_filter((0, 3), 'A')

slider = pn.widgets.RangeSlider(start=0, end=3, name='A Filter')
filter_table.add_filter(slider, 'A')

select = pn.widgets.MultiSelect(options=['foo1', 'foo2', 'foo3', 'foo4', 'foo5'], name='C Filter')
filter_table.add_filter(select, 'C')


def print_(event):
    print(event.new)

filter_table.param.watch(print_, "value")


pn.Row(
    pn.Column(slider, select, width=500, height=250),
    filter_table,
    height=500,
    width=1000
).servable()

Did you manage to find a solution to this? I’ve run into the same problem.

I don’t think so, but maybe try selected

There is no public api for reacting to and getting the filtered data as far as I can see. But its available via filter_table._get_data()[0]. So you can do something like this

import pandas as pd
import panel as pn
pn.extension("tabulator")
pn.config.sizing_mode = "stretch_both"

mixed_df = pd.util.testing.makeMixedDataFrame()
filter_table = pn.widgets.Tabulator(mixed_df, width=1000, height=200)

filter_table.add_filter((0, 3), 'A')

slider = pn.widgets.RangeSlider(start=0, end=3, name='A Filter')
filter_table.add_filter(slider, 'A')

select = pn.widgets.MultiSelect(options=['foo1', 'foo2', 'foo3', 'foo4', 'foo5'], name='C Filter')
filter_table.add_filter(select, 'C')


@pn.depends(value1=slider, value2=select)
def get_filter_data(value1, value2):
    return filter_table._get_data()[0]


pn.Column(
    slider,
    select,
    filter_table,
    "# Filtered Data",
    get_filter_data,
    height=500,
    width=1000
).servable()

If you think the filtered dataframe should be publicly available please post a feature request on github Issues · holoviz/panel (github.com). (I think it should be :-))