Hi @Emmanuelle Thank you helping out. Here are more information.
It’s not a sub-plot, We are using html.Div -> dcc.Tab -> dcc.Graph
here is a sample code snippet of say 4 graphs
app = dash.Dash(
__name__, external_stylesheets=["https://codepen.io/chriddyp/pen/bWLwgP.css"]
)
auth = dash_auth.BasicAuth(
app,
VALID_USERNAME_PASSWORD_PAIRS
)
app.layout = html.Div(children=
[
html.H1("Dashboard [Updated: " + date_val + " ]", style={'color':'blue','fontsize':16}),
dcc.Tabs([
############### Tab 1 #############################
dcc.Tab(label='Summary', children=[
dcc.Dropdown(id='province-picker1',options=province_list,value='All'),
dcc.Graph( id='Summary-Graph0', style={"width": "20%","display": "inline-block" }),
dcc.Graph( id='Summary-Graph1', style={"width": "20%","display": "inline-block" }),
dcc.Graph( id='Summary-Graph2', style={"width": "20%","display": "inline-block" }),
dcc.Graph( id='Summary-Graph3', style={"width": "20%","display": "inline-block" }),
dcc.Graph( id='Summary-RoutineWithData', style={"width": "20%","display": "inline-block"}),
and call back look like below
@app.callback(Output('Summary-Graph0', 'figure'),
[Input('province-picker1', 'value')])
def update_summary0(province_val):
return {
'data' : [ go.Indicator(
mode = "gauge+number",
value = index_df['index_cases'].sum(),
domain = {'x': [0, 1], 'y': [0, 1]},
title = {'text': "Index Cases"} ,
gauge = { 'bar': {'color': "darkred"}})
],
'layout': go.Layout(autosize=True,margin={'t': 0,'l':0,'b':0,'r':10})
}