If a section is collapsed and a new filter is chosen, then the matching items are displayed, even if in the collapsed section.
If the table is filtered and a section is expanded, then all items in the expanded section are displayed regardless of whether they match the filter.