The shiny application I'm working on is displaying graphs using ggplotly. In an instance when the resulting dataset is empty, a blank plot is being displayed, as below.
Is it possible to show a custom message such as 'No data exists with the selected inputs' instead of an empty plot
With the help o...

I have an issue when using ggplotly on a ggplot graph. It is basically the exact same issue as here. However, the offered solution does not work if the plot is not facetted, since the object gp[['x']][['layout']][['annotations']] that should be altered does not exist in this case. (Unfortunately, I...

I had the same issue described in this question:
R: ggplot and plotly axis margin won't change
but when I implemented the solution, I got the following error:
Warning: Ignoring unknown aesthetics: text We recommend that you use the dev version of ggplot2 with ggplotly() Install it with: devtools::in...

I am new to plotly. I'm wondering how I could add a slider control to a heat map colour bar that allows the user to only show tiles that are of a specific value/colour? Any tips would be appreciated. Thank you.
library(plotly)
p

I am able to plot a geom_bar as I want but when I try to wrap it with the ggplotly function it does not work. Anyone know a trick to make it work?
library(ggplot2)
library(plotly)
# My df dataset
a=runif(10, min = 0, max = 1)
b=runif(10, min = -1, max = 0)
df=data.frame('p'=c(a,b),
'g'=rep(c('a','b'...

I am building an app that allows a user to dynamically add and remove traces on a plotly graph using selectInput.
I have tried to play around with plotlyProxy () and plotlyProxyInvoke () from plotly package to no avail.
Below is my rudimental code :
library(shiny)
library(shinydashboard)
library(plo...

I'm trying to convert a ggplot2 image using ggplotly(), but it's not converting correctly. My ggplot image takes in two lines all of the time, and has a color variable for the geom_line component and a fill variable for the geom_point component.
Here is my code for the strictly the basic ggplot part...

I'm trying to do something seemingly simple: when the user clicks on a data point or select multiple points with lasso selection, I want to draw these points in a different colour. In order to do that, I look at what points are selected, and add a col variable to the dataframe, and I tell the ggplot...

I am trying to create a plotly graph for a shiny app. I am running into an issue with certain layouts of faceted plots. Whenever there are four facets and they are in a 2x2 grid, the bottom left facet does not display any data even though the data is there in the ggplot figure. This also happens whe...

I'm using plotly::ggplotly() and I need the user to be able to both select a single point and to select multiple points with brushing. I want both selection options to exist in parallel. The user should be able to click on a point and to lasso select several points, and both of those pieces of infor...

I make a list of ggplots stored in an object called g.a, Here's the code to reproduce the plots (data is provided at the bottom).
Worth to note that I am probably missing something simple and over-complicated the problem.
RCfitter

I have made a map using ggplot and plotted it using ggplotly.
When it is in ggplot it looks like this:
But when it is displayed using ggplotly, it looks like this:
As you can kind of see, the individual regions are sort of splurging all over the place, without clear borders, and the fill is kind of...

I have created a shiny app to show a correlation heatmap for a large dataset. When the heatmap tiles are pressed, the corresponding scatterplots are displayed.
However, I need to make several of these apps and this exceeds my limit of publishing on shinyapps.io. My company is unwilling to upgrade to...

So I have three columns, ID, When user logged on, and for how long he was logged on (in seconds). here is a sample from it (total user are more than 4000):
structure(
list(
id = c(
'id_1', 'id_2', 'id_3', 'id_4', 'id_5', 'id_6', 'id_7', 'id_8', 'id_9',
'id_10', 'id_11', 'id_12', 'id_13', 'id_14', 'i...

I'm using ggplotly to convert a ggplot object to interactive plotly. The problem I'm encountering is when the ggplot object is using an associated color aesthetic.
For example, using the following dummy example:
library(ggplot2)
library(plotly)
datetime.data = seq.POSIXt(from = ISOdatetime(2017, 10...

Former R user, I used to combine extensively ggplot and plot_ly libraries via the ggplotly() function to display data.
Newly arrived in Python, I see that the ggplot library is available, but cant find anything on a simple combination with plotly for graphical reactive displays.
What I would look f...

I would like to change the shape and size of the clicked point in the below plot. How to achieve it? For this toy plot, I have reduced the number of points from original 100k to 2k. So, the expected solution should be highly scalable and do not deviate from the original plot i.e., all the colors bef...

I want to create a bar plot with Descending bars, In the plot below, due to NA being present at 2nd spot in 'a1' vector, it is pushed at the last when the plot is created. However, I want the NA bar to be present at the 2nd spot only, kindly help me here as I want to achieve this without modifying m...

I have a plot which I have created with plotly. When I deploy it to my shiny app the X and Y labels are cut off as you can see here:
How can I prevent this from happening? If I use a normal plot the labels do not get cut off but I need the plot to be interactive.
Here is my code for creating the pl...

I've had some success extending ggflags to use SVGs, and now I'm trying to make this extension play nice with ggplotly(). The Plotly documentation has a nice section on translating custom geoms, and it essentially comes down to either providing a to_basic method for your geom or a geom2trace method....

I am trying to format the data labels that appear when I hover over part of a chart I have created using Plotly. The label is currently showing like this. I would like for the label to only show profit.
My code for creating the plot is:
output$monthlyProfits

the given script simply creates a process map diagram showing the flow of events in R. This field of study is called event log mining or process mining. I wish to know any other packages or functionality in R using which I can create similar maps and also make them interactive like ggplotly. Please...

I am trying to plot some data in a ggplotly plot.
The x-axis contains dates. Ggplotly doesn't work well with dates as when I hover over a point, the date is displayed as a number.
I solved this by setting a tooltip like below.
Some sample data:
x

I'd like to make my scatterplot points clickable and have each point's respective hyperlink open when clicked. I am trying to do this using ggplotly.
There is a simple way to do this when building the plot using plotly()(see first example below). However, when running it on ggplotly, an empty webpag...

I was wondering if there's a way to have a custom icon for plotly's pie chart instead of the usual pie division
As of now I'm displaying the gender information using a pie chart which looks as below:
I'm trying to make it look like the gender plot in the link below:
https://app.displayr.com/Dashboar...

I've created a map in R using ggplotly. To create a link, it needs to be 524kb or under, but it currently is 1.2Mb. Are there any good ways of reducing file size so I can export it? Or is this totally unrealistic?