如何调试FactoInvestigate错误:无法打开连接

任何人都遇到此错误:

Error in readChar(con,5L,useBytes = TRUE) : cannot open the connection

我正尝试使用以下方法调查MCA结果:

Investigate(MCA_res,file = "MCA.Rmd",document = c("word_document","pdf_document"))

> Investigate(MCA_res,"pdf_document"))

this hits an error after the following steps:
-- creation of the .Rmd file (time spent : 0s) --
-- detection of outliers (time spent : 0s) --
0 outlier(s) terminated 
-- analysis of the inertia (time spent : 0.08s) --
12 component(s) carrying information : total inertia of 54.3% 
-- components description (time spent : 6.25s) --
plane 1:2 
plane 3:4 
plane 5:6 
plane 7:8 
plane 9:10 
plane 11:12 
-- classification (time spent : 7.04s) --
3 clusters 
-- annexes writing (time spent : 7.24s) --
-- saving data (time spent : 8.83s) --
-- outputs compilation (time spent : 8.83s) --

Quitting from lines 13-15 (MCA.Rmd) 
**Error in readChar(con,useBytes = TRUE) : cannot open the connection**
In addition: Warning messages:
1: In if (document == "Word" | document == "word" | document == "doc" |  :
  the condition has length > 1 and only the first element will be used
2: In if (document == "html" | document == "HTML" | document == "HTML_document") { :
  the condition has length > 1 and only the first element will be used
3: In if (document == "pdf" | document == "PDF") { :
  the condition has length > 1 and only the first element will be used
4: In if (document == "word_document") { :
  the condition has length > 1 and only the first element will be used

我们将不胜感激任何理解这一点的人。

Tx
Rj

peeky1 回答:如何调试FactoInvestigate错误:无法打开连接

问题在于需要加载的“ Workspace.RData”的地址。我通过更改源代码“ R / Investigate.R”第74行来解决:

writeRmd(paste0("library(FactoMineR)\nload('",getwd(),"/Workspace.RData')"),file = file,start = TRUE,stop = TRUE,options = "r,echo = FALSE")

代替

writeRmd"library(FactoMineR)\nload('~/Workspace.RData')"),echo = FALSE")
本文链接:https://www.f2er.com/2972415.html

大家都在问