The*_*Man 5 r rstudio data.table
比较这种行为,
df <- data.frame(a11111 = rnorm(5,0), b11111= rnorm(5,0))
df$a # pressing tab at this instance auto-completes a11111
df$a # hitting return at this instance returns the value for a11111
Run Code Online (Sandbox Code Playgroud)
有这种行为:
library(data.table)
dt <- data.table(df)
dt[,a # pressing tab at this instance does not auto-complete a11111
dt[,a # pressing return at this instance returns an 'object not found' error
dt$a # behaves like how it does for the data frame
Run Code Online (Sandbox Code Playgroud)
我认为返回是有效的,因为x$name相当于x[["name", exact = FALSE]]?但是,我不了解自动完成行为.由于data.table语法基于[,是否实际和/或可能dt[,a <tab/return>工作dt$a<tab/return>?
我在Windows 7,64位上运行Rstudio 0.97.551和R版本3.0.1.
| 归档时间: |
|
| 查看次数: |
242 次 |
| 最近记录: |