简体   繁体   English

正在加载ggplot2软件包,缺少“ munsell”软件包

[英]Loading ggplot2 package, missing 'munsell' package

I am trying to load ggplot2. 我正在尝试加载ggplot2。 I am using Windows 7. R tells me that ggplot2 has loaded successfully but when I try to use the library function it says it cannot find ggplot2. 我正在使用Windows7。R告诉我ggplot2已成功加载,但是当我尝试使用library函数时,它说它找不到ggplot2。 Here is what it says. 这就是它的意思。

install.packages("ggplot2")
Installing package into ‘C:/Users/Owner/Documents/R/win-library/3.1’
(as ‘lib’ is unspecified)
trying URL 'http://cran.rstudio.com/bin/windows/contrib/3.1/ggplot2_1.0.0.zip'
Content type 'application/zip' length 2675581 bytes (2.6 Mb)
opened URL
downloaded 2.6 Mb

package ‘ggplot2’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in
    C:\Users\Owner\AppData\Local\Temp\RtmpyesS1j\downloaded_packages

I then tried to use the library function and got this message: 然后,我尝试使用library函数并收到以下消息:

library("ggplot2")
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) : 
  there is no package called ‘munsell’
Error: package or namespace load failed for ‘ggplot2’
> head(diamonds)
Error in head(diamonds) : object 'diamonds' not found

I hope someone has an idea about what I have done wrong. 我希望有人对我做错了什么有个想法。

应该执行以下命令:

install.packages("ggplot2", dependencies=TRUE)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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