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.
3,730
questions
0
votes
0
answers
12
views
KeyError warning from pandas dataframe inside plotly dash chained callback
My debut! Ok. Just really want to understand what's up with this.
I got a code I'm working on, very first swing at dash, where I'm using chained callbacks but can't, for the life of me, realize why I'...
0
votes
0
answers
23
views
Plotly Dash Plot Line
I'm working on Dash in python and I have a problem on a graph plot.
I have to draw many lines (separated between them).
But I don't know how to do it. I start from a dataframe containing the XY of ...
1
vote
1
answer
17
views
How to switch between multiple tabs with buttons in Dash and also how to reset a button after click once?
I am looking to find a way to switch between multiple tabs by clicking buttons present inside the tabs. I am unable to find a way to reset a button after it is click once so the app won't fail if ...
0
votes
0
answers
6
views
Plotly express (px) component inside dash core component (dcc)
I'm trying to insert a scatter plot inside a tab as in the code below however nothing seems to work. I have tried a number of combinations with dash HTML elements, inserting children= etc and I gave ...
0
votes
0
answers
18
views
Application of Features of Plotly in Dash such as "landcolor"
I have a chart resulted by plotly:
cmap = matplotlib.cm.Blues(np.linspace(0,1,40))
CCC= cmap[4]
fig = go.Figure()
fig.add_trace(go.Scattergeo(
lon = MEDIUM.Longitude,
...
0
votes
0
answers
20
views
Integrate browser SVG-to-PNG conversion in a Plotly/Dash app
I have a multipage Dash app that generates some SVG graphics which are also converted to PNG to be inserted into markdown and ODT/LibreOffice documents. Currently I use cairosvg for conversion but it ...
0
votes
0
answers
10
views
Update several plots with slider in Python Dash
I am rather new to Dash (and basic skill level regarding Python) and working on a dashboard for educational purposes.
Students shall be able to alter various variables via sliders. The changes on an ...
0
votes
0
answers
13
views
How to add callback to authentication in dash
So, let's imagine I have this code
import os
from pydoc import classname
import dash
from dash import dcc, html
from datetime import datetime
# from dash import html
# from dash import dcc
from dash....
0
votes
0
answers
11
views
Do i need to pip install dash[dev] or just dash
what is exactly the role of [dev] in dash[dev]?
Do i need it, to be able to build my own components?
I already tried building some components with success so far.
0
votes
0
answers
19
views
How to encrypt file before upload using dash-uploader
I want to build an uploading tool in plotly DASH, that will take any file, encrypt it using python's cryptography.fernet and upload it. To circumvent the limitations of dcc.upload component, I am ...
0
votes
0
answers
13
views
Python Dash - title above each dropdown menu
I am stuck in trying to figure out how to make the second title above the dropdown menu (see highlighted circle picture).
This is my current code for the app layout:
app.layout = html.Div([
html....
0
votes
1
answer
32
views
Plotly Dash: How to align the tooltip to the top instead of top right
I would like the tooltip (highlighted part of the image below) to appear on the top of the vertical bar, while it is currently on the right.
Even explored documentation of plotly bar charts and saw ...
-2
votes
0
answers
28
views
Connecting Choropleth Map With Scatter Chart
I am new to this plotly dash environment. I am trying to build a dashboard, where I have two main components
1: Agriculture parcels (blue boxes on right side of the map)
2: Statistics of each parcel.
...
0
votes
0
answers
10
views
Use edited dash.dash_table outputted from callback as inputs to future callback functions
I use a callback & and a pandas dataframe to create and show a dash.dash_table that I'm able to show. Great.
However, I want to be able to manually override the values in this dash.dash_table and ...
0
votes
0
answers
14
views
Dash Extra spacing around the image
I have edited the margin to 0 but I am still getting big white space around the image that I imported. I am not sure how I can fix this. THE RESULT IMAGE IS HERE.As you can see, there are always some ...
0
votes
0
answers
22
views
How to change the node sizes individually in a networkx graph in Plotly Dash
I am creating a networkx graph and while developing in Python I can change the node size using the following code in networkx.draw_shell() -
vertices = df_final.columns.values.tolist()
edges = [((u,v),...
0
votes
1
answer
17
views
Plotly Dash | Remove minor ticks
Goal: Run example code and run example with and without minor ticks.
Plotly documentation has example code of a graph with minor ticks. Running the code fails.
import plotly.express as px
import ...
0
votes
0
answers
13
views
How to generate a plotly chart studio link with subplots
I am trying to build a Dash application in python that prints out three charts on localhost:8050,
For example, here are three figures which are returned with dcc.Graph
def funct(data, x_data, ...
0
votes
1
answer
20
views
Change X,Y and Z axis at (0,0,0) in Scatter 3D plot using Plotlyexpress
I wish to plot a 3D scatter plot using plotly.express and wish to fix the X,Y and Z axis at (0,0,0) rather than the minimum value. I tried with matplotlib and changed the ylim and xlim but there is no ...
0
votes
0
answers
8
views
Dash datatable width parameter does not work for style_header
Since I use dash, I have some annoying problems with the style_header parameter of the dash_table.Datatable component.
Indeed, some of them like the colors / background colors work while others like ...
1
vote
0
answers
12
views
Integrating bulma css framework with dash plotly
Question
How to integrate bulma(css framework) to style dash app? The docs indicate use of a cdn or css file should work.
Attempt
app.py(dash)
from dash import Dash, html
app = Dash(__name__)
app....
-1
votes
0
answers
27
views
Dash boostrap components installation
Could not find the version that satisfied the requirements for dash_boostrap_components.
I encountered the error while trying to install dash boostrap components with pip on python 3.10
pip install ...
1
vote
1
answer
26
views
How to avoid 'ID Not Found in Layout' with initial loading of app?
The below code functions correctly. The problem is that upon the initial loading of the app, the ID of the datatable cannot be found. I believe this is because it has not yet been created.
How do I ...
0
votes
0
answers
12
views
live update graph and click button are incompatible in dash framework?
I would like to put logout button and live update graph in one page.
but when I try, the graph updated very fast regardless of n_interval argument.
is there any way to put click button and live update ...
0
votes
0
answers
13
views
Serving static content in Dash using a nginx subfolder
I have a Dash application serving static content like this
app = dash.Dash(url_base_pathname='/gifts/')
dbc.CardImg(src=app.get_asset_url("pizza.jpg")),
The images are all placed in the ...
0
votes
0
answers
20
views
Assigning multiple values per row within a Dash DataTable
I'm having trouble making a part of my code a little more efficient. What I'm trying to do, is add stock data with the 'yfinance' package to a Dash DataTable that contains the ticker name. What I have ...
0
votes
1
answer
28
views
How to add button to plotly chart to toggle multi traces?
how to add button like this below to toggle data from all traces on the scatter?
Thanks,
Paulina
0
votes
1
answer
24
views
Plotly error 'Invalid argument `figure.data` passed into Graph'
I'm following a tutorial here to build a plotly dashboard. I've spent the whole day looking for solution or trying to solve it on my own but no luck. Ideally it should upload a xy, xyy,xyyy... type of ...
0
votes
2
answers
40
views
How to update range_color in Plotly Express?
I am using plotly express and I want to display some data:
import plotly.express as px
dfx = px.data.tips()
fig = px.scatter(dfx,
x='total_bill', y='tip',
color='...
0
votes
0
answers
26
views
Dash - update data Table Live is very long
I've just developped an app with two containers:
Worker container is fetching data from physical equipments and stores it into a CSV.
Api container is a Dash app which is reading the CSV and displays ...
0
votes
0
answers
5
views
I am trying to create a population pyramid graph using Dash with Plotly
i have a directory containing three files, years.csv, 2014.csv and 2015.csv. i want to plot a population pyramid graph for the two files but i want pandas to pick the dataframe from the years.csv with ...
0
votes
0
answers
36
views
Deploy Django on Plotly Dash Enterprise (Docker/Herokuish/Gunicorn/nginx)
Good Evening,
I am attempting to install a Django and run the development server and production WSGI on Dash Enterprise. I'll preface this with I am also fairly new to Python and Django but not ...
0
votes
1
answer
18
views
Plotly: How to set an interval of '10' on both the axis where the range is as follows [0,100]
How to set an interval of '10' on both the axis where the range is as follows [0,100]
0
votes
0
answers
20
views
Dash Uploader will not work with files above 1Mb
This uploader is for .xlsx files. It doesn't work with files above 1.0Mb, but works fine with files smaller than this.
I have max_file_size set well above this.
Running this locally, I can upload any ...
0
votes
0
answers
27
views
How to get Relayout Data from plotly graphs plotted via a list
I am trying to build an app that shows list of images which are dynamic. I need to select part of any one of the image using rectangle component and need to do OCR on top of that. I am trying to use ...
0
votes
0
answers
18
views
Dash deployment with NGINX-Uwsgi-Django failing when running with multiprocess
I have a stack that looks like this:
NGINX (nginx.conf):
worker_processes 8;
events {
worker_connections 1024;
use epoll;
multi_accept on;
accept_mutex off;
}
upstream django {
...
0
votes
0
answers
19
views
Am trying to visualize data from multiple csv files and i would like to choose which file through a drop down and then create a graph for that file
This is my code, am trying to create a population pyramid and i want to be able to select which file is read into the dataframe by pandas using a drop down. On changing the dropdown item, the graph ...
0
votes
0
answers
23
views
How to display elements of a list from a dataframe column as multiple rows/lines in a dash data table?
I have a data frame where one column (Top_users) is a list. I want to create a dash data table out of it but I can't display the list elements as rows of their own or at least as multiple lines of the ...
0
votes
1
answer
30
views
How to create a filterable Dash datatable where the data comes from an uploader
I am attempting to create a datatable that can be filtered. The source of the data is pulled in after clicking the button, and this is what I am having trouble working around.
In my actual app, the ...
0
votes
1
answer
35
views
How do I get my columns to align side by side in Plotly dash and DBC?
Trying to get these graphs side by side but for some reason they keep showing up on top of each other. I even tried to adjust the width and now its just two stubby graphs stacked and still not side by ...
1
vote
0
answers
17
views
Python Dash Plotly > Delete previous point data
I am trying to create a live updating graph with Plotly Dash with Python. Is there any way to delete the previous (first data input) data point and only plot the incoming one? This is my code:
import ...
1
vote
0
answers
41
views
Connecting local data to Docker Django project
This is a question to understand what should be the best practice to follow in order to connect the dots on the argument. Currently I am developing a Dockerized Django website. In this website, one of ...
-1
votes
0
answers
9
views
Integrate Dash app into Flask, sometimes cannot load the dashboard
I have created a dashboard using Dash and integrated it into a web app built with Flask.
The example of code is below:
import dash
# create dash app
def create_dashapp(server):
app = dash.Dash(
...
0
votes
1
answer
26
views
Dash - search and display results in datatable
I have a dataframe of patient records as rows and various features as columns.
I'd like to be able to search through this dataframe based on one feature and display the rows that correspond to that ...
0
votes
2
answers
27
views
How to is "facet_row" for "add_scattergl"?
Here I want to plot the fault for every every sub plots according to there unit. how to use "facet_row" for "figline.add_scattergl(x=df2.DateTime, y=df2.Value.where(df2.DataType=="...
0
votes
1
answer
36
views
How to show the result of NetworkX graph in Plotly.Dash using Dash callbacks
I have a list of edges between several nodes of a graph as a .csv file. I am reading the mentioned file and storing it in a Dash Store component like below:
dataset = pd.read_csv(io.StringIO(decoded....
0
votes
0
answers
11
views
Is there an equivalent of DCC.Store in Flask?
I built a dashboard in Dash, however the requirements of my development forced me to embed my multi page dashboard into a Flask server in order to create authentication and authorization.
I created a ...
0
votes
1
answer
21
views
Creating proper columns in python dash
I am trying to create a dashboard with python dash and want two or more columns. Unfortunately I always end up with all the content stacked row wise. What am I missing here?
from dash import Dash, dcc,...
0
votes
0
answers
18
views
Dash Plotly secondary axis scatter plot
I try to put scatter plot with secondary axis into Dash app and getting strange error. I tried many option but not sucsess... maybe you see whats wrong.
This is my code:
def scatter_1() -> dcc....
0
votes
1
answer
14
views
Dash | I no longer have Duplicate IDs but still get error
New to Dash; so go easy on me.
Error:
dash.exceptions.DuplicateIdError: Duplicate component id found in the initial layout: `num2-bool`
This is because I had 2 Python objects with id='num2-bool'.
I ...