简体   繁体   中英

Can't Load statnet in R on Windows 10

I have run

install.packages('statnet')
library('statnet')

Result:

Loading required package: tergm

Loading required package: ergm

Error: package or namespace load failed for 'ergm' in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]): there is no package called 'statnet.common'

Error: package 'ergm' could not be loaded

In addition: Warning messages: 1: package 'statnet' was built under R version 3.4.4 2: package 'tergm' was built under R version 3.4.4

Error: package 'ergm' could not be loaded 5. stop(gettextf("package %s could not be loaded", sQuote(pkg)), call. = FALSE, domain = NA) 4. .getRequiredPackages2(pkgInfo, quietly = quietly) 3. library(pkg, character.only = TRUE, logical.return = TRUE, lib.loc = lib.loc, quietly = quietly) 2. .getRequiredPackages2(pkgInfo, quietly = quietly) 1. library(statnet)

Next I tried

install.packages('ergm') # Worked with warning: dependency ‘statnet.common’ is not available

But library(statnet) still does not work, and library(ergm) has a similar error message.

Also tried install.packages(statnet.common) but also get

package 'statnet.common' is not available

I'm running RStudio Version 1.1.419, with R version 3.4.3 on Windows 10

Any ideas how to load statnet in R?

将我的R版本更新到3.5.3解决了我的问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM