Questions tagged [plotly]

1

votes
2

answer
41

Views

Error in plotting time series data with plotly, truth value is ambiguous

I am trying to use plotly express to chart time series data. I am receiving this error.There isn't any boolean values in my code so I don't understand why it isn't able to crunch this code. ValueError: The truth value of a Index is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all(). I've...
Michael Holborn
3

votes
1

answer
14

Views

How do I create a scatterplot in python to depict vectors within a given output?

Hi im new to python and trying to learn plot viz I have an output from my dataframe: df.groupby('Type').mean() Out[29]: Rating Reviews Size Installs Type Free 4.167469 269978.303527 35.166263 7.720880e+06 Paid 4.252677 5612...
lil zuzu
1

votes
0

answer
326

Views

Plotly - Dynamically Choose X and Y Variables for Scatter Plot

I'm trying to create a scatter plot where the user can dynamically change the X and Y axis. I have it mostly completed, but I'm running into this weird hiccup. The first time I change the X dropdown, the scatter plot will be incorrect. However, once I change the Y dropdown the scatter plot corrects...
CoolGuyHasChillDay
1

votes
0

answer
27

Views

Does Plotly support headline numbers?

I'm looking to create a report/dashboard and I want to include a headline number on top. For example, if the report is 'Monthly Sales Report' I want the top line to be something like: $15,100 new revenue booked this month And then various charts, tables, whatnot beneath. I like a lot of Plotly's fu...
ScottieB
1

votes
2

answer
292

Views

Is it possible to disable the zoom/pan window on a plotly.py candlestick chart?

I am creating a candlestick plot using plotly.py. I would like to have a horizontal split and place the candlestick data in the top split and some data curves in the bottom bottom split. I do not need panning and zooming and that lower section of the candlestick chart with the zoom/pan controls is g...
mbilyanov
1

votes
1

answer
181

Views

Turn off projected lines in plotly

How do I turn off the lines that are projected onto the 3 axis planes of the plot when hovering over the data? I haven't been able to figure out which setting is used to switch these off. plot with projected lines library(plotly) # data x
telfer
1

votes
0

answer
184

Views

Plot inside of hoverinfo in Plotly

I've a plotly bar chart with a hover event which plots another plot alongside the first one Is there a way to have the second plot show up inside of the hoverinfo box ? The code I used is as under: UI library(shiny) library(plotly) library(shinythemes) library(dplyr) library(png) ui
Dee V
1

votes
1

answer
509

Views

can't import plotly libraries (Python)

I am having a bit of trouble getting my plotly imports to work. I am a new Python programmer. I followed the following instructions to a 'T': https://plot.ly/python/getting-started/ When I copied the demo code into pycharm, I got errors on the imports. So I found a guy who had the same question as...
rocksNwaves
1

votes
0

answer
689

Views

Python Plotly: autosize table plot

I'm plotting tables of different sizes with Plotly that I want to export as an image. However the size of the plot doesn't automatically scale with the table size resulting in only part of the table displayed in the image (or lot's of white space if I set the plot size too large). I know I can make...
JuuLes87
1

votes
0

answer
55

Views
1

votes
0

answer
55

Views

PlotlyJS rescale yaxis when xaxis range is updated (via rangeslider)

I have the sample chart with range slider created with PlotlyJS: It uses API endpoint to fetch data. Now, the slider can be used to change xaxis range like: but then the chart looks strange as yaxis has this fixed range and visible data covers only small vertical part of the whole chart. Is it possi...
f1ames
1

votes
0

answer
273

Views

I am trying to create one graph using plotly but keep on getting this error Error in arrange_impl(.data, dots)

I am trying to create one graph using plotly but keep on getting this error. Any help is appreciated Error in arrange_impl(.data, dots) : Evaluation error: argument 'value' is missing, with no default. Code looks like this: plot_ly(Graph_lost, x = ~Month_Year, y = ~Final_Series_AfterLost,type='sc...
Kajeet
1

votes
1

answer
285

Views

R plotly flat surface in 3d scatterplot

I am trying to add a flat surface to this plot (Excuse the size, if I make it bigger the file is too large). The surface should be parallel to the ground with the third dimension equal zero. It should go through the red points. Code to reproduce: n.cases
Steinroe
1

votes
1

answer
640

Views

plotly-dash on iis with flask and wfastcgi

I've configured IIS with python and wfastcgi.py, getting it working, mostly. When trying with simple stuff, it returns the expected content. My issue now is with getting flask and plotly/dash working under IIS, using attribute routing. My web.config is as follows: I've created an index.py file and w...
Kim Ipsen
1

votes
0

answer
72

Views

plotly numeric yaxis formatting

I have a python plotly graph with numeric yaxis, it automatically formats the yaxis numbers to 'k' scale and and when hovering the point, shows values like 115.277258k. How can I change the scale to display 100,000 instead of 100k and also format the hovering text to show 115,2772.58 instead of 115...
BRS
1

votes
0

answer
320

Views

Save .png by webshot in R

I'm using webshot to save a png file from HTML : p % add_area(color = ~nms)%>% layout(radialaxis = list(ticksuffix = '%'), orientation = 270) saveWidget(as.widget(p), 'temp.html') webshot('temp.html',file = 'temp.png',cliprect = 'viewport') This is giving me a plot like this. It returns a small imag...
user9112767
1

votes
0

answer
83

Views

Making Axis Clickable in Plotly.js with React

I want to make the x-axis in my chart clickable and run a function when it's clicked. I tried the following code but it didn't work. How do I make it such that the function handleClick executes when I click on the labels in the x-axis? export default class MyComponent extends React.Component { const...
fliang111
1

votes
1

answer
248

Views

Is there a datatip class or way to script one in python dash similar to matlabs datatip?

---Update--- 1/27/2018 After looking into it. I have figured that I need to go a little different direction. Python Dash looks like the best option to go but I am still having some problems figuring out how to make the graph dynamic and add annotations to the graph as I click on data points. I w...
Nate
1

votes
0

answer
105

Views

Show specific plane (XY) in plotly 3D Scatterplot in R

With showgrid = TRUE for x-axis and y-axis, is there any way to get rid of the VERTICAL lines extending from the x and y-axis so that there is a single plane showing? library(plotly) itemName = c('Alpha', 'Bravo', 'Charley', 'Delta', 'Echo', 'Foxtrot') security = c(0.8583241, 0.7516891, 0.5390520,...
craab
1

votes
1

answer
549

Views

3D biplot in Plotly in Python

I want to plot something like a biplot in python Plotly ,but using 3 principal components so as to make a 3d plot. How do I go about plotting the direction vectors(the red lines) of principal components in plotly python? There is exactly the same question , but for R, here. I am not able to transl...
GeneX
1

votes
1

answer
111

Views

Defining outer edge of filled 2d Contour plot in plotly

Problem: I am trying to reproduce a round filled 2d contour plot in R using plotly (have tried ggplot2 also but plotly seemed to be easier). Data: Sample data download link - https://drive.google.com/file/d/10Mr5yWVReQckPI6TKLY_vzPT8zWiijKl/view?usp=sharing The data to be plotted for contour is in...
Tarun Parmar
1

votes
0

answer
149

Views

Plotly-Generate JSON in R, save and reuse in html/javascript

It there a simple example of how to: Export the plotly json file from an R plotly plot Save this file Reuse this file to generate a plot in a webpage using the plotly.js library I have generated the a json file for a plot (p1): json
user3633239
1

votes
0

answer
205

Views

problems with plotly and plot_mapbox

I'm trying to make a plotly plot that should be rather straightforward, but am having some difficulty. What I'd like to do is plot each of the lat and longs and color them based on the count column. If I hover over a location, I should see the name in the name field. I feel as though the code bel...
Chris
1

votes
0

answer
56

Views

Dynamically delete points in plotly graph

How can I delete points from a plotly generated HTML graph and have the fit line adjust dynamically? I don't want to change the data in the code. I would also like to update the equation of the line. Here is the code: import plotly.plotly as py import plotly.graph_objs as go import plotly # Scien...
user2233706
1

votes
1

answer
390

Views

Ploting scatter marker symbols from an image in plotly R

I want my marker symbols to be images from a file instead of default symbols as listed here. I searched but couldn't find a way to use an image file for the symbols. Let's say I have a data.frame dt
SamAct
1

votes
0

answer
157

Views

using plotly and python to chart simple timesries but over 200K point

I have a big time series data which I would like to plot simple X by time(y) in pycharm (offline. need a local chart) I was tried this code: import plotly.plotly as py import plotly.graph_objs as go data = [go.Scatter(x=data.Clients, y=data.Timestamp)] py.iplot(data) but got an error: Woah there! L...
Giladbi
1

votes
0

answer
36

Views

foreign-object content not appearing in plotly

I was trying to wrap html content into plotly chart to apply text-overflow to the tick labels by using foreignObject. All these implementations did it in plotly_afterplot event. But it's strange content is not appearing which is in foreignObject. I tried following the suggestion, which is suggested...
ur truly friend
1

votes
0

answer
282

Views

How to view graph created by cufflinks/plotly using spyder IDE

I'm running the code below to try and create a simple scatter plot of of the dataframe OAT_df. The code runs fine but nothing appears? How do I find the graph that is produced? See code below OAT_df.iplot(kind = 'scatter', filename = 'cufflinks/simple-line')
Julie
1

votes
1

answer
293

Views

Tick labels for latitude and longitude on scatter geo maps in plotly

How do I add tick labels (ie. the latitude and longitude in degrees) to scatter geo maps in plotly (python)? If I take for example Plotly's North American Precipitation Map and within the layout=dict() add... yaxis = dict( showticklabels=True ), ...nothing changes. On the reference page, there is al...
spacetyper
1

votes
0

answer
61

Views

I am having trouble using the Dropdown Event in a 3D chart on R-Ploty

First I do not speak English well. Please understand that point.. I created a data frame like the code I attached in R. What I want to do is draw each x, y, z 3D line graph with the value of the ID column of the data frame. In addition, I want to add a visible event for each ID line via updatemenus....
Ungurrer
1

votes
0

answer
135

Views

Adding a colorbar to a plotly scatter plot with polygons behaves oddly

This follows up to this post. I have xy data I'd like to generate a scatter plot for using plotly. I want to have polygons surrounding clusters of the points. Data: set.seed(1) df
dan
1

votes
0

answer
46

Views

Plotly & geo data - hovertext not shown

I'm trying to work with the geospatial functions of R and plotly. The map does what it should - except the hover text. It is not shown and I really don't understand why. Here the data: Datum City LAT LONG ZIEL_LAT ZIEL_LONG 11.07.2016 München 48 11 51 8 16.07....
Johnny Banana
1

votes
2

answer
328

Views

Python Dash Framework Networking

I'm learning Dash library for creating dashboards. I'm in Dash Tutorial - Part 1: App Layout When i run my app.py file in cmd. It shows: Running on http://127.0.0.1:8050/ (Press CTRL+C to quit). Then i can open app in my web brower at the SAME computer using url it give me. But it doesn't work when...
Yehui He
1

votes
0

answer
125

Views

How to share the same Z axis on 2 plotly Heatmap subplots

I would like to set the same Z axis for 2 heatmap subplots. Currently, plotly generates 2 independents scale and superimposes them. Here is where I am for the moment, but cannot manage to merge both scales... import plotly.offline as py import plotly.graph_objs as go from plotly import tools fig =...
Maxime
1

votes
0

answer
681

Views

use django template with dash application

I have set-up a dash application that works well with my django website, but I would like to have the dash application on a page that has a template. The setup I have is the usual one, that is : views.py def dispatcher(request): ''' Main function @param request: Request object ''' params = { 'data':...
Boidot
1

votes
1

answer
177

Views

How to handle the Warning “Ignoring explicitly provided widget ID ; Shiny doesn't use them”?

I have already gone through similar questions previously posted here on StackOverflow such as How to address explicit widget id warning for a shiny app using metricsgraphics?, but the fixes proposed are not showing any results for me. On the dashboard, only a blank plot shows up, that is only with...
Raghu Aditya
1

votes
0

answer
65

Views

How to fit Plotly plot size dynamically

Previously I asked a question how to fit Bokeh plot size dynamically and I got a solution from HYRY. How to fit bokeh plot size dynamically Now I would like the same question for the Plotly plot. Similarly to HYRY's method, I could achieve the same effect using Plotly.relayout javascript function: T...
Royalblue
1

votes
0

answer
537

Views

How to create plotly stacked bar chart with lines connecting the bars at corners

I'm trying to create a stacked bar chart with lines connecting the corners of the bars, like in the image provided (the dashed black lines between the bars). I'm doing this with plotly offline in Spyder. I also want to display percentage change on those (dashed) lines. What I want: Code I have so fa...
Moni
1

votes
1

answer
240

Views

Plotly r, line style by variable

I am trying to make a scatter plot where the line style is specified by a factor variable, just as one does with colors, but I can't get it to work. library(plotly) df
Tobias D
1

votes
0

answer
23

Views

How to connect UI to network libray which is connected to redis?

I have this sever and client('Raspberry pis'). Now I have to read the sever and clients from redis db and get messages and show it in Frontend UI. I am using DASH frame work. How can I achieve application sever and read the live updates enter image description here Something like in this pic and I a...
Anhsirk Krishna

View additional questions