R studio List 和 Dataframes 自动名称完成不再起作用 [英] R studio List and Dataframes auto name completion not working anymore

查看:42
本文介绍了R studio List 和 Dataframes 自动名称完成不再起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在输入 mylist$ 然后按 Tab 时,R Studio 突然停止自动完成我的列表和数据框内容.我得到的结果消息是

Suddenly R Studio stopped auto completing my list and data frame contents when entering mylist$ then pressing Tab. The result message I get is

没有匹配项

我在非常简单的列表或数据框上尝试过,例如:

I tried that on very simple lists or data frames like:

 simpledataset <- data.frame(a=rep(0,100),b=rep(1,100))   

但是,当我加载数据集 Mtcars 时,它正确地显示了列名.

However, when I load the dataset Mtcars, it correctly shows the column names.

我通过重命名重置了 %localappdata%\RStudio-Desktop,但没有改变任何东西.

I reset %localappdata%\RStudio-Desktop by renaming it, but didn't change anything.

知道是什么原因造成的吗?

Any idea of what could be the cause of that?

推荐答案

这听起来像是自动完成系统中的一个错误,在加载某些包或增加字节编译器优化设置时偶尔会触发.您可以尝试检查以下几点:

This sounds like a bug in the autocompletion system that is occasionally triggered when certain packages are loaded, or the byte-compiler optimization setting is increased. You might try checking a few things:

  • compiler::getCompilerOption("optimize") 的值是多少?当此值等于当前 RStudio 版本 (v0.99.896) 中的 3 时,已知自动完成会失败.您可以尝试运行 compiler::setCompilerOptions(optimize = 2) 来解决这个问题.

  • What is the value of compiler::getCompilerOption("optimize")? Autocompletion is known to fail when this value is equal to 3 in the current RStudio release (v0.99.896). You can try running compiler::setCompilerOptions(optimize = 2) to resolve this.

你加载了什么包?您可以尝试一一加载包,看看哪些会影响 RStudio 提供自动补全的能力.

What packages do you have loaded? You can try loading packages one-by-one to see which affects RStudio's ability to provide autocompletions.

最后,在 RStudio 的预览版中应该有一个修复程序——你可以在 https://www.rstudio.com/products/rstudio/download/preview/.

Finally, there should be a fix for this in the preview version of RStudio -- you can try it out at https://www.rstudio.com/products/rstudio/download/preview/.

这篇关于R studio List 和 Dataframes 自动名称完成不再起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆