[英]When loading data in Rstudio getting error "ReadItem: unknown type 161, perhaps written by later version of R"?
When I am trying to load a clean data in Rstudio, file name called salesClean.RData, I am getting error.当我尝试在 Rstudio 中加载一个名为 salesClean.RData 的干净数据时,出现错误。
Error message is: ReadItem: unknown type 161, perhaps written by later version of R
报错信息是:
ReadItem: unknown type 161, perhaps written by later version of R
Screenshot of error message:报错信息截图:
Here is what worked for me: 这对我有用:
Simple Solution: 简单的解决方案:
Try to use the tool Load Workspace . 尝试使用工具“ 加载工作区” 。 It allows you to select the Rds file and load it into memory.
它允许您选择Rds文件并将其加载到内存中。
Best Solution: 最佳解决方案:
In some cases you do need to load the file programatically. 在某些情况下,您确实需要以编程方式加载文件。 In these situations you will probably prefer get your R up to date.
在这些情况下,您可能更希望更新R。 You can do this by running the code:
您可以通过运行代码来做到这一点:
install.packages("installr")
require(installr)
updateR()
Also, you can update your installed packages in RStudio on Tools > Check for packages updates. 另外,您可以在RStudio的“ 工具”>“检查软件包更新”中更新已安装的软件包。
Make sure that you're using the latest version not only of Rstudio, but R as well. 确保不仅使用Rstudio的最新版本,而且还使用R的最新版本。 Try
sessionInfo()
command, it should say that you have R version 3.1.2. 尝试
sessionInfo()
命令,它应该说您具有R版本3.1.2。
In my case, finally I found it's because the hard disk under my root is full. 以我为例,最后我发现这是因为根目录下的硬盘已满。 I freed some disk memory and re-saved the
.RDdata
file, the load
works again. 我释放了一些磁盘内存,然后重新保存了
.RDdata
文件, load
再次起作用。
For me, had a very similar experience to @CcMango, though for me it was because I had run out of session memory. I restarted my Rstudio session with fresh memory and loaded fewer files and that solved it.对我来说,与@CcMango 有非常相似的经历,尽管对我来说这是因为我用完了 session memory。我用新的 memory 重新启动了我的 Rstudio session 并加载了更少的文件并解决了它。 For similar issues, I've had luck rewriting in batches or querying from other sources too.
对于类似的问题,我也有幸批量重写或从其他来源查询。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.