Iβm trying to add a vline to a subplot (in position row 2, col 1), it works fine without subplots, but with the subplot it fails. FWIW subplot 1,1 is table. Any advice? Relevant snippets of code:
# Prepare table subplot
fig = make_subplots(
rows=2, cols=1, row_heights=[0.2,0.8],
vertical_spacing=0.03,
specs=[[{"type": "table"}],
[{"type": "scatter"}]]
)
if table_cols_exist:
# Create table and chart
for index, trace in enumerate(data):
if index==0:
fig.append_trace(trace, row=1, col=1)
else:
fig.append_trace(trace, row=2, col=1)
else:
# Create chart only
fig = go.Figure(data=data, layout=layout)
for changepoint in signif_changepoints:
fig.add_vline(x=changepoint, line_width=0.8, line_dash="dot", line_color="darkslateblue", row=2, col=1)
which returns the following error
PlotlyKeyError: Invalid property specified for object of type plotly.graph_objs.Table: 'xaxis'