Questions tagged [plotly-dash]

Dash is a framework for building data visualisation web applications. The original release was for Python, but Julia and R versions of the framework are also now available.

Dash is written on top of Plotly.js and React.js, and its Python implementation uses Flask on the backend.

Extensive documentation and a gallery of examples are available.

Dash is an open source library, released under the MIT license.

Enter image description here

Enter image description here

Enter image description here

4538 questions
1
vote
2 answers

Run a Python script in Dash Callback

I'm trying to run a Python script in a Dash callback function but my current code is not doing it as I intended. For example, there's a button called "Open" and once a user click on it, it will open a modal and run the python script. On the modal…
sgrimes
  • 149
  • 2
  • 11
1
vote
1 answer

Python Dash does not display plot

I'm trying to create a dashboard where I take a string as an input, process it in backend, and then generate a graph to display as output. However, when I run, I only see the input field and on clicking Submit, nothing happens. The graph itself is 3…
1
vote
1 answer

How to sort legends alphabetically in plotly dash with category_orders function

I am using Plotly dash for creating a scatter plot. The legends I am getting in the final figure are randomly placed. I want to sort labels alphabetically from A to Z with category_orders function fig = px.box( df, …
Riya
  • 113
  • 4
1
vote
1 answer

dash DataTable reset on page reload

The following code reads a simple model (3 columns 50 rows) from a CSV file for editing in a table in my (larger) dash app. Editing a cell writes the whole table back to file as expected. However, reloading the page displays the table as it was…
1
vote
1 answer

Change stacked bar graph color with dropdown

I'm trying to create a stacked bar chart and then change color of it by dropdown value. Below is my sample code: import pandas as pd import numpy as np import plotly.express as px import dash from dash import html from dash import dcc from…
hoa tran
  • 1,391
  • 1
  • 5
  • 14
1
vote
1 answer

Plotly Dash Boostrap drop down menu is rendered behind the the plotly graph objects. Is there a way to stop this?

I'm making a plotly - dash app that has a navigation side bar to browse through the different app pages (see code below). One of the navigation items contains a dbc.DropDownMenu that hangs over the edge of the navigation side bar into the main…
1
vote
0 answers

Start and end date on the same line. Date Picker Range Python Dash

I'm using Date Picker Range from dash components in python. However, in the documentation it has the start date and end date on the same line, but when I do it it is on two lines. Does anyone know how to adjust this? in my code in the…
1
vote
1 answer

Callback error (Output graph.figure is already in use.) in Dash app - Python

I have this dataframe which will be updated every several minutes: Sample Name Result Concentration Mean Diameter 0 A 244 122 8 1 A 150 8 3 2 A 133 …
mariant
  • 131
  • 10
1
vote
0 answers

Null is not an object (evaluating 'r.data') in Dash app - Python

I have this script for callbacks in my Dash app: @app.callback(Output('graph', 'figure'), [Input(component_id='graph-dropdown', component_property='value')], [Input('interval-component', 'n_intervals')]) def…
mariant
  • 131
  • 10
1
vote
1 answer

plotly: add box plot as subplot

I'm attempting to create a visualization where a pie chart appears on top, and a box plot appears below. I'm using the plotly library. I tried using this code: import plotly.express as px import plotly.graph_objects as go from plotly.subplots import…
pb_lull
  • 23
  • 3
1
vote
1 answer

how to change html.Img() style in callback?

I am using html.Img(src='image.png',style={'height':'300px', 'width':'100%') to add image. I'd like to change image size in callback for different images, one thing I can think of is to change style of image to change image size in callback. I don't…
roudan
  • 3,082
  • 5
  • 31
  • 72
1
vote
1 answer

How to update Dashboard (dash/plotly) with new data uploaded to the folder?

I have built a Dashboard using dash and plotly which is plotting data from the excel file located on my local PC. The data in the excel file will be updated on a daily basis but I don't know what should I do, so that the Dashboard gets updated as…
mariant
  • 131
  • 10
1
vote
0 answers

What is the best way to run a background process in a Dash app?

I have a Dash application that queries an API, based on a user search query, performs some calculations on the response, then displays the final results to the user on a Dash app. In order to provide a quick response to the user, I am trying to set…
1
vote
1 answer

Dash Bootstrap Components: Some inputs not styled correctly when using dark theme

I wrote an app with Plotly Dash / Dash Bootstrap Components (dbc). It looked fine when using a light theme (Spacelab), but with dark themes (I tried Darkly and Cyborg), dropdowns and selects are not styled correctly - they should have a white…
Thomas
  • 4,696
  • 5
  • 36
  • 71
1
vote
0 answers

Update simulation results into a live-dash-graph

I've done a simulation and while the code is running I want to show a live-updating-graph. In this case I want to show the cost in every week. X= date, y= cost. The last part of simulation code is something like: def simulation(path, df, orders,…
K-Chris
  • 11
  • 1
1 2 3
99
100