[Rd] tcltk and R

Peter Dalgaard pd.mes at cbs.dk
Mon Mar 15 17:32:19 CET 2010

Gabor Grothendieck wrote:
> I have had some comments on sqldf regarding its dependence on tcltk
> such as the second last sentence on this blog post:
> http://translate.google.com/translate?hl=en&sl=zh-CN&u=http://www.wentrue.net/blog/%3Fp%3D453&prev=http://blogsearch.google.com/blogsearch%3Fhl%3Den%26ie%3DUTF-8%26q%3Dsqldf%26lr%3D%26sa%3DN%26start%3D10
> sqldf does not directly use tcltk but it does use strapply in gsubfn
> for its parsing and strapply uses tcl from the tcltk package to it
> speed up -- there is also an all R version of strapply but the gsubfn
> package as a whole still depends on tcltk whether or not the user uses
> tcltk or not.    I was thinking of changing the Depends:tcltk of
> gsubfn to Suggests:tcltk and then checking for tcltk availability at
> run time so if not available it would use the slower all R version;
> however, I was under the impression that all R platforms have a
> distribution of R that includes tcltk so in principle this should not
> be necessary.
> Is that right regarding tcltk availability on various platforms?  What
> is the situation here?

Hmm, judging by the Mac situation, I wouldn't count on it. We have tcltk
working on all the major platforms, but we do allow for compilation
without it (e.g. for compute servers), and at least in the Mac case, we
need to use a suboptimal version because of the event loop battle. If
Apple didn't support X11 (well, sort of), we'd be without Tk there.

(We do, byt the way, handle the case where the display is absent, but
there really ought to be a neater way to load Tcl without Tk.)

Peter Dalgaard
Center for Statistics, Copenhagen Business School
Phone: (+45)38153501
Email: pd.mes at cbs.dk  Priv: PDalgd at gmail.com

More information about the R-devel mailing list