tcltk in portable R

2019-07-18 09:13发布

问题:

I am using portable R and I want to try the sqldf package a bit, I can load the sqldf package, but running a sql statement and gives me this message:

> sqldf("select * from BOD where Time > 4")
Loading required package: tcltk
Loading Tcl/Tk interface ...Error : .onLoad failed in loadNamespace() for 'tcltk', details:
  call: NULL
  error: Tcl/Tk support files were not installed
Error: require(tcltk) is not TRUE

I have looked for solutions but most of them suggest me to install R, which is not possible as I am using portable R.

What can I do? Thanks.

回答1:

install R 2.13.1 for Windows, copy ~/R-2.13.1/Tcl folder to ~\R-Portable\App\R-2.11.1 and ~/R-2.13.1/library/tcltk folder to ~/R-Portable/App/Data/library

I tried and it works.



回答2:

See sqldf FAQ #5