Buttons to filter on different column than colors

I have a bar chart with a dropdown menu to filter on column values. The buttons filter based on the color of the graph.

I want the colors to represent a different column than the filter. Is this possible?