R代码在Rstudio中'运行'很好但是没有devtools :: load_all()检查

时间:2016-03-14 16:03:17

标签: r rstudio devtools

当我在Rstudio中运行它时,这行代码正常工作

dt.SSPGDP[, GDP.lag1 :=shift(value), by=c("ISO_code","scenario")]

但是当我运行devtools :: load_all()时,我收到以下错误消息

Error in `:=`(GDP.lag1, shift(value)) (from dataManagement.alcohol.R#37) : 
  Check that is.data.table(DT) == TRUE. Otherwise, := and `:=`(...) are defined for use in j, once only and in particular ways. See help(":=").

我检查过dt.SSPGDP实际上是一个数据表。

有关如何修复的提示吗?

0 个答案:

没有答案
相关问题