I'm plotting a graph for the dataframe - link the code looks like -
client = ['av']
x_axis = 'recall_at_k'
y_axis = 'precision_at_k'
color_group='facilityname'
graph_width = 1200
graph_height = 600
marker_size = 7
cutoff_marker_size = 18
symbol_group='rank_cutoff'
text = 'info'
title="test figure"
fig = px.scatter(
plot_df,
x=x_axis,
y=y_axis,
color=color_group,
title=title,
width=graph_width,
height=graph_height,
text=text
)
fig.update_traces(marker={'size': np.where(plot_df['is_cutoff']==1, cutoff_marker_size, marker_size), 'line':{'width':2, 'color':'DarkSlateGrey'}},textfont_size=1)
fig.show()
Here, the 'is_cutoff' column is a boolean column and I want to make the marker size bigger when is_cutoff's value is '1'.
The problem I'm facing is that plotly is making the marker size bigger at places where 'is_cutoff' value is '0'.
to test the graph - just look at the graphs for 'cala' and 'each'. image link