R: 找不到函数 "igraph2graphjs"

R: could not find function "igraph2graphjs"

我正在尝试使用 threejs 包为网络绘制交互式图形。但是,当我尝试将 igraph 对象转换为 threejs 对象时,出现以下错误:

Error in igraph2graphjs(net) : could not find function "igraph2graphjs"

我用谷歌搜索了一下,没有找到解决办法。有没有人有想法。我关注教程网站:http://kateto.net/network-visualization

问题是您无法访问 igraph 对象 net。据我所知,threejs 包的当前版本 (v0.3.1) 中没有名为 igraph2graphjs 的函数。它确实存在于版本 0.2.2 中。看来教程已经过时了。有效的示例代码:

# SNAP Facebook ego network dataset
data("ego")
(graphjs(ego, bg="black"))

您使用 graphjs 函数创建 igraph 对象的交互式 3D 图。无需转换。

Windows 上的 RStudio 存在一个已知问题,导致图形无法渲染:

RStudio on Windows systems may not be able to render the WebGL graphics emitted by threejs. RStudio users running on Windows systems may need to use the plot "pop out" button to see visualizations in an external browser. We expect this to be a temporary problem until the underlying graphics rendering system used by RStudio is updated later in 2017.