[R] converting "call" objects into character
Gabor Grothendieck
ggrothendieck at gmail.com
Tue Apr 5 13:13:30 CEST 2011
On Sun, Apr 3, 2011 at 12:14 PM, Samuel Le <Samuel.Le at srlglobal.com> wrote:
> Dear all,
>
>
>
> I would like to log the calls to my functions. I am trying to do this using the function match.call():
>
>
>
> fTest<-function(x)
>
> {
>
> theCall<-match.call()
>
> print(theCall)
>
> return(x)
>
> }
>
>
>
>> fTest(2)
>
> fTest(x = 2)
>
> [1] 2
>
>
>
> I can see "theCall" printed into the console, but I don't manage to convert it into a character to write it into a log file with other informations.
>
See ?trace
--
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com
More information about the R-help
mailing list