Closed joey711 closed 9 years ago
It seems to be something to do with JavaScript not picking up the zoom when the graph is appended to a div
, as opposed to the body
. (You'll notice the same issue over at http://bl.ocks.org/benzguo/4370043, where zoom doesn't work, but it does when appended to the body http://bl.ocks.org/benzguo/raw/4370043/).
I'll keep looking into it.
I don't think the issue was what I mentioned above.
I did a test of attaching the chart to a div
with parentElement
. Zooming works with this outside of Shiny, but not in. Hm. . .
There seems to be a (somewhat) related problem with dragging links from sankey diagrams
Same problem here in my application. My network plots are in tabs on a shiny page. I'm thinking that I might write the javascript to a temporary file and then open the javascript in a new window for a more detailed view and the ability to zoom. So far I've only got this working in my head, but I'm thinking the following structure will work. Write the standalone javascript to a temporary.html that is in a place that an nginx server can serve the content. Then I need to give the link to that file on the shinypage. Any thoughts on thins strategy? Is this overly complex?
Still haven't found a good solution to the zoom problem in Shiny. Using an iframe from another file might indeed work.
@christophergandrud , I found the same issue with Shiny, but I swear that zoom function worked once out of my 20 attempts :). This package is really good work and hope to see this solved soon.
That's very curious.
I love the package, I am also hitting the zoom problem. It did once work for me - very early in the cycle Are there any workarounds?
@NickStrange What version are you using?
Hi Thanks for getting back to me.
Nick
R version 3.2.0 (2015-04-16) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 7 x64 (build 7601) Service Pack 1
locale: [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 LC_MONETARY=English_United States.1252 [4] LC_NUMERIC=C LC_TIME=English_United States.1252
attached base packages: [1] stats graphics grDevices utils datasets methods base
other attached packages: [1] rjson_0.2.15 shiny_0.12.1 d3Network_0.5.2.1
loaded via a namespace (and not attached):
[1] R6_2.0.1 plyr_1.8.3 htmltools_0.2.6 tools_3.2.0 whisker_0.3-2 Rcpp_0.11.6 digest_0.6.8
[8] xtable_1.7-4 httpuv_1.3.2 mime_0.3
Sent from my iPad
On Jun 15, 2015, at 11:44 AM, Christopher Gandrud notifications@github.com wrote:
@NickStrange What version are you using?
— Reply to this email directly or view it on GitHub.
Have you tried networkD3?
I have just tried that. That solves the problem.
Thanks for your time
Nick
Sent from my iPad
On Jun 17, 2015, at 2:56 AM, Christopher Gandrud notifications@github.com wrote:
Have you tried networkD3?
— Reply to this email directly or view it on GitHub.
Great. FYI d3Network is no longer supported so please use networkD3 when possible.
I can set the
zoom
option ind3ForceNetwork
toTRUE
, but the resulting app remains in the default configuration, no-zooming.