Hello,
First of all, I would like to thank the Dash community, it is a wonderful tool and you guys are awesome!!
I believe I hit a road block, I’ve spent days googling and experimenting, but I haven’t been successful so far. Basically I have a Pandas dataframe and I create multiple dropdowns to each column with dropdowns containing column’s unique values. For example, the dataframe may look like this:
col-A col-B col-C col-D
A1 B1 C1 D1
A1 B1 C2 D2
A2 B2 C2 D3
A2 B2 C3 D4
and the dropdowns have value of: d-A: {A1, A2}, d-B: {B1, B2}, d-C: {C1, C2, C3}, d-D: {D1, D2, D3, D4}
What I’m trying to achieve is a mimic of Spotfire filter panel, i.e., changing value of ANY of these dropdowns would dynamically update the rest of dropdowns by recalculating the unique values. For example,
1> if user picks A1 in d-A, the rest of 3 dropdowns becomes d-B: {B1}, d-C: {C1, C2}, d-D: {D1, D2}
2> if user pick C2 in d-C, the rest of 3 dropdowns becomes d-A: {A1, A2}, d-B: {B1, B2}, d-D: {D2, D3}
As you can see, the difficulty is that each dropdown is an output and an input simultaneously, and also we don’t know which dropdown users decide to click first. So that’ll create a infinite callback loop. I wonder if there’s a way to overcome this problem. Thank you in advance!
Jake