0

我在尝试安装 statnet 包时收到以下警告和错误消息:

> installing *source* package 'statnet' ...
> 
> package 'statnet' successfully unpacked and MD5 sums checked
> 
> R
> 
> inst
> 
> byte-compile and prepare package for lazy loading
> 
> Warning: package 'tergm' was built under R version 3.5.3
> 
> Warning: package 'ergm' was built under R version 3.5.3
> 
> Warning: package 'network' was built under R version 3.5.3
> 
> Error: package or namespace load failed for 'network' in
> loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck =
> vI[[j]]):  there is no package called 'tibble'
> 
> Error : package 'network' could not be loaded
> 
> ERROR: lazy loading failed for package 'statnet'
> 
> removing 'C:/Users/Users/Documents/R/win-library/3.5/statnet
> 
> In R CMD INSTALL
> 
> Warning in install.packages :
> 
>   installation of package ‘statnet’ had non-zero exit status

我可以知道如何解决这个问题吗?提前致谢!

4

1 回答 1

0

首先,我会重新启动您的 R 会话。错误信息:

there is no package called 'tibble'

表示您没有该tibble包。类似的,错误信息

Error : package 'network' could not be loaded

表示您没有该network包。

我将通过键入以下命令在控制台上安装这些软件包:

install.packages(c("tibble", "network"),dependencies=TRUE))

然后尝试安装你的包。

install.packages("statnet", ,dependencies=TRUE))
于 2019-07-09T16:29:51.060 回答