[R] using sprintf to pass a variable to a RMySQL query

Uwe Ligges ligges at statistik.tu-dortmund.de
Thu Mar 11 16:01:08 CET 2010


On 10.03.2010 12:45, alison waller wrote:
> Thanks Gabor,
>
> As I said I would like to use gsubfn, but I am having problems
> installing it, which I assume are due to some conflict with the current
> tcltk package
>
> Below is the error I got after issuing install.packages("gsubfn")
>
> Any advice?


Re-install R including the tcltk package?

Uwe Ligges


> ###################
> * Installing *source* package 'gsubfn' ...
> ** R
> ** demo
> ** inst
> ** preparing package for lazy loading
> Warning: S3 methods '$.tclvar', '$<-.tclvar', 'as.character.tclObj',
> 'as.character.tclVar', 'as.double.tclObj', 'as.integer.tclObj',
> 'as.logical.tclObj', 'print.tclObj', '[[.tclArray', '[[<-.tclArray',
> '$.tclArray', '$<-.tclArray', 'names.tclArray', 'names<-.tclArray',
> 'length.tclArray', 'length<-.tclArray', 'tclObj.tclVar',
> 'tclObj<-.tclVar', 'tclvalue.default', 'tclvalue.tclObj',
> 'tclvalue.tclVar', 'tclvalue<-.default', 'tclvalue<-.tclVar' were
> declared in NAMESPACE but not found
> Error in namespaceExport(ns, exports) :
>    undefined exports: addTclPath, as.tclObj, is.tclObj, is.tkwin
> Error : package 'tcltk' could not be loaded
> ERROR: lazy loading failed for package 'gsubfn'
> * Removing '/g/bork3/x86_64/lib64/R/library/gsubfn'
>
> The downloaded packages are in
>          '/tmp/RtmpkfvT5f/downloaded_packages'
> Updating HTML index of packages in '.Library'
> Warning message:
> In install.packages("gsubfn", lib = "/g/bork3/x86_64/lib64/R/library") :
>    installation of package 'gsubfn' had non-zero exit status
>
> ########## this is the error when I tried to install tcltk#
> install.packages("tcltk")
> Warning message:
> In getDependencies(pkgs, dependencies, available, lib) :
>    package 'tcltk' is not available
>
>
>
> On 03/09/10 16:26, Gabor Grothendieck wrote:
>> On Tue, Mar 9, 2010 at 7:10 AM, alison waller<alison.waller at embl.de>  wrote:
>>
>>> Hi all,
>>>
>>> Thanks for help with the paste and sprintf syntax.
>>>
>>> So I've decided to use paste and or sprintf.  'gsubfn' looks like a
>>> great package but unfortunately I've had problems installing it, as I
>>> don't think it likes the version of tcltk that is installed.  I'm
>>> working on a few unix clusters with many computers and there seems to be
>>> problems with different versions of R and different versions of the
>>> packages on different computers.
>>>
>> The fn$ functionality that I mentioned does not use the tcltk package
>> so the version of tcltk should not matter.
>>
>> The only part of the package that uses tcltk is strapply, which is not
>> used here, and even in that case there is R code to it as well if you
>> use strapply(..., engine = "R") or use ostrapply.
>>
>> Also the older 0.3-9 version of the gsubfn package did not use tcltk at all.
>>
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list