Dashboards bouwen met Dash en Plotly
Alex Scriven
Data Scientist
Een complete Dash-app:
from dash import Dash, dcc
app = Dash()
app.layout = [dcc.Graph(id='example-graph', figure=bar_fig)]
if __name__ == '__main__':
app.run(debug=True)
print("f{my_variable}")
from dash import Dash, dcc
Dash initialiseert de app dcc bevat UI-componenten zoals grafieken en inputs
app = Dash()app.layout = [dcc.Graph( id='example-graph', figure=bar_fig)]
Dash()app.layout indcc.Graph()figure = de Plotly-figure om te tonenid = belangrijk voor callbacks later
if __name__ == '__main__':
app.run(debug=True)
python my_app.py in de command linedebug geeft feedback tijdens testen
Toegang via een browser zoals Google Chrome
Terwijl de server draait, de .py-file updaten en opslaan om live updates te zien in de browser



Dashboards bouwen met Dash en Plotly