I have a DataFrame with all my data and i have the following stage order
order = {0:'NEW',1:'FOLLOW_UP',2:'Demo',3:'QUOTE',4:'CLOSING'}
fig = px.funnel(df, x='count', y='name', color='source',category_orders=order)
My DataFrame is perfectly in desired Order as the Order dictionary, but my graph keeps switching positions with QUOTE and DEMO.
It actually makes no difference if category_orders is used or not, tried a bunch of dictionaries styles and arranges but none seem to work.
Documentation category_orders (dict with str keys and list of str values (default {})) – By default, in Python 3.6+, the order of categorical values in axes, legends and facets depends on the order in which these values are first encountered in data_frame (and no order is guaranteed by default in Python below 3.6). This parameter is used to force a specific ordering of values per column. The keys of this dict should correspond to column names, and the values should be lists of strings corresponding to the specific display order desired.
Check the image of my funnel here