-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uncaught TypeError: Cannot read property 'cluster' of undefined #13
Comments
This is one where @timelyportfolio or @ramnathv might be able to help |
Without a reproducible example, not much I can do unfortunately. |
Thank you @garthtarr. I added 'd3r' and 'htmlwidgets', but they did not solve my problem. |
@jiansongatnih could you provide a reproducible example filling in the library(edgebundleR)
library(shiny)
library(networkD3)
server <- function(input, output) {
##
}
ui <- fluidPage(
sidebarLayout(
sidebarPanel(
##
),
mainPanel(
tabsetPanel(
tabPanel("edgebundle",
##
),
tabPanel("d3network",
##
)
)
)
)
)
shinyApp(ui = ui, server = server) |
@garthtarr I really appreciate your help on this! I was thinking about how to provide you an example to show what's my problem. It gave me the same javascript error as I notice with my app in a browser (Chrome).
|
Thank you @garthtarr! |
Thanks for the reprex @jiansongatnih I see the issue. Unfortunately, there's no quick fix, an option might be to use an iframe ramnathv/htmlwidgets#58 As @timelyportfolio mentions here #12 ,
I guess I should move edgebundleR to d3v4, but then it looks like we'd have a similar issue with other htmlwidgets that were still using d3v3. |
Thank you @garthtarr! Followed your suggestion, I was able to display my igraph in iframe. But I had to save the igraph to a html file and move the file to 'www' folder in Shiny. Again thanks!
|
edgebundleR worked fine by itself in my ShinyApp, but I could not display a D3 network generated by networkD3. No error in my ShinyApp, but got the following javascript error in my browser. Apparently there is a conflict between edgebundleR and networkD3. I want to display my network in both on two different tabs. I would greatly appreciate it if you could help me to find a solution!
Uncaught TypeError: Cannot read property 'cluster' of undefined edgebundleR.js:30
at Object.drawGraphic (http://127.0.0.1:6080/edgebundleR-binding-0.1.4/edgebundleR.js:30:29)
at Object.renderValue (http://127.0.0.1:6080/edgebundleR-binding-0.1.4/edgebundleR.js:12:10)
at exports.OutputBinding.shinyBinding.renderValue (http://127.0.0.1:6080/htmlwidgets-0.9/htmlwidgets.js:516:20)
at exports.OutputBinding.onValueChange (http://127.0.0.1:6080/shared/shiny.min.js:4:9871)
at exports.OutputBinding.delegator.(anonymous function) [as onValueChange] (http://127.0.0.1:6080/htmlwidgets-0.9/htmlwidgets.js:112:23)
at OutputBindingAdapter.onValueChange (http://127.0.0.1:6080/shared/shiny.min.js:4:29679)
at ShinyApp.receiveOutput (http://127.0.0.1:6080/shared/shiny.min.js:3:26802)
at ShinyApp. (http://127.0.0.1:6080/shared/shiny.min.js:3:28780)
at ShinyApp._sendMessagesToHandlers (http://127.0.0.1:6080/shared/shiny.min.js:3:28585)
at ShinyApp.dispatchMessage (http://127.0.0.1:6080/shared/shiny.min.js:3:28375)
The text was updated successfully, but these errors were encountered: