Rstudio无法编织 [英] Rstudio will not knit
问题描述
Rstudio无法编织.我在一个课程中已经使用了几个星期.
Rstudio will not knit. I have been using it for a few weeks in a course.
当我尝试编织时,它会一直执行直到涉及某些代码,然后停止.代码是
When I try to knit it executes until it comes to some code and it stops. The code is
ggplot(数据= gss,aes(x =年,填充=度))+ geom_bar()
ggplot(data = gss, aes(x = year, fill = degree)) + geom_bar()
消息是
找不到函数"ggplot"
could not find function "ggplot"
其他功能也会发生这种情况.注释掉的代码将运行并生成一个HTML文件.
This happens with other functions as well. With the code commented out is will run and produce an HTML file.
我已经重新安装了R和Rstudio两次.我在使用AV软件(Bitdefender)阻止安装某些应用程序时遇到了困难.该软件是几个星期前更新的新版本.
I have reinstalled R and Rstudio twice. I have had difficulty with my AV software (Bitdefender) blocking the install of some of the apps. The software is a new version updated a couple of weeks ago.
推荐答案
请在文件中使用任何功能之前将文件装入文件(R Markdown?您没有说). ,library(ggplot2)
.
Please load the package in the document (R Markdown? You didn't say) before you use any functions in it, e.g., library(ggplot2)
.
这篇关于Rstudio无法编织的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!