无法安装任何 R 包,无法转换为本机编码

每当我打开 Rstudio 时,我都会收到一条红色消息:

Error in gzfile(file,mode) : cannot open the connection
In addition: Warning messages:
1: In list.files(cacheDir) :
unable to translate 'C:/Users/<U+03A7>a<U+03C1><U+03B7><U+03C2>/AppData/Local/RStudio/explorer-cache' to native encoding
2: In gzfile(file,mode) :
cannot open compressed file 'C:\Users\×áñçò\AppData\Local\Temp\RtmpEZExey\rstudio-available-packages-23783cacb6/time.rds',probable reason 'No such file or directory'.

我的PC用户名是用外文写的,但从上面的文字可以看出,Rstudio错误地将其写为“×áñçò”。

每当我尝试安装包时,Rstudio 根本没有响应,当我尝试关闭它时,我收到消息“正在检索包安装上下文...”并且我在那里停留了一段时间,直到我得到控制台中的此错误:

WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/
Warning in install.packages :
cannot create dir 'C:\Users\×áñçò\AppData\Local\Temp\Rtmpw9xEQw\downloaded_packages',reason 'No such file or directory'
Error in install.packages : unable to create temporary directory ‘C:\Users\×áñçò\AppData\Local\Temp\Rtmpw9xEQw\downloaded_packages’

无法安装任何 R 包,无法转换为本机编码

我已经尝试了一切,从重新安装,从以管理员身份运行 Rstudio,但这些都不起作用!你能帮我吗?

谢谢。

weichaochenweichao 回答:无法安装任何 R 包,无法转换为本机编码

暂时没有好的解决方案,如果你有好的解决方案,请发邮件至:iooj@foxmail.com
本文链接:https://www.f2er.com/1031.html

大家都在问