I've tried to google why this isn't working but it doesn't appear obvious to me. Can you please tell me why the selection dropdown isn't changing the graph? Thanks
source = data.unemployment_across_industries.url
df = data.unemployment_across_industries()
series_val = df.series.str.split(',').explode().unique().tolist()
print(series_val)
input_dropdown = alt.binding_select(options=series_val, name='Industry: ')
selection = alt.selection_single(fields=['series'], bind=input_dropdown)
fig3 = alt.Chart(source).mark_area().encode(
alt.X('yearmonth(date):T',
axis=alt.Axis(format='%Y', domain=False, tickSize=0)
),
alt.Y('sum(count):Q', stack='center', axis=None),
alt.Color('series:N',
scale=alt.Scale(scheme='category20b')
)
).add_selection(
selection
)
fig3