Black Lives Matter. Please consider donating to Black Girls Code today.
Dash Enterprise delivers an incredible 21x cost savings 💸Download the e-book!

Unable callback graph

Unable to display graph using callback in dash. Core components are loading perfectly. Getting blank page on the dashboard

Below is my sample code:

external_stylesheets = [‘’]
app = dash.Dash(‘name, external_stylesheets=external_stylesheets’)
animals=[‘giraffes’, ‘orangutans’, ‘monkeys’]

app.layout = html.Div([
html.H1(children=‘Confusion Matrices’),
Confusion Matrix of Ensemble Models

@app.callback(Output(‘bar-graph’, ‘children’),
[Input(‘actual-data’, ‘animals’)])

def bar_graph(animals):
bar_fig = go.Figure([go.Bar(x=animals,y=[10,23,60])])
children = [ dcc.Graph(
id = ‘example’,
figure = bar_fig)]
return children

app.css.append_css({‘external_url’: ‘’})

if name == ‘main’:

Hi @dmb007, inside the callback you are using the id ‘actual-data’ as an input. But I can’t find any element in your layout with this id. Don’t have to add an input element to your layout?