For this example I've got a list of names with a variety of categories they can belong to.
I'd like to generate a sublist of names based on which category they're in which would appear in the cell the formula's in, using the cells below for additional names.
E.g. (poorly laid out text version because my org won't let me share publicly)
Name.....| Cat 1 | Cat 2 | Cat 3
Fred.....|...1...|.......|...1
Geoff....|.......|...1...|
Gertrude.|...1...|...1...|...1
Abigail..|.......|.......|...1
try in F2:
=FILTER(A2:A; FILTER(B2:D, B1:D1=F1)=1)