From @KoningD
Example https://plot.ly/r/sankey-diagram/#basic-sankey-diagram under Add Links gives the error:
Error in proposed[["hoveron"]] : subscript out of bounds
I tried it with the following versions:
r version 3.5.1, plotly_4.8.0
r version 3.4.2, plotly_4.8.0
Thank you for your work.
You said you fixed the bug, but unfortunately, the same error still appears.
I tested your code with R version 3.5.1, plotly_4.8.0.
I'm trying to draw a Sankey diagram, but I see the same type of error repeatedly.
Please help me!
I didn't say it was fixed, I just moved the issue's location
I encountered the same problem when my Sankey chart stopped working after upgrade to plotly 4.8.0. Reverting to 4.7.1 fixed the problem ofcourse (devtools::install_version("plotly", "4.7.1")). I had upgraded to 4.8.0 to get a fix for the following warning as described in https://github.com/ropensci/plotly/issues/985.
Warning in origRenderFunc() :
Ignoring explicitly provided widget ID "63f851f7f801"; Shiny doesn't use them
As it turns out, the example itself has a bug...the domain
should be a list of two atomic vectors (both of length 2):
domain = list(
x = c(0,1),
y = c(0,1)
)
Not an atomic vector with four elements:
domain = c(
x = c(0,1),
y = c(0,1)
)
If anyone sees this error due to a different problem please let me know.
Verified, works with
domain = list(
x = c(0,1),
y = c(0,1)
)
Most helpful comment
As it turns out, the example itself has a bug...the
domain
should be a list of two atomic vectors (both of length 2):Not an atomic vector with four elements:
If anyone sees this error due to a different problem please let me know.