Re: [R] determining a parent function name

From: Vladimir Eremeev <wl2776_at_gmail.com>
Date: Thu, 31 May 2007 05:10:13 -0700 (PDT)

Vladimir Eremeev wrote:
>
> Does
> tail(capture.output(traceback()),n=1)
> do what you want?
>
> that is
>

Hmmm... Seems, no...

Having the earlier error() definition and

bar<-function() error("asdasdf")
ft<-function() bar()

> ft()

I get in the tcl/tk window:

Error in bar(): asdasdf

> bar()

I get in the tcl/tk window:

Error in ft(): asdasdf

> I get in the tcl/tk window:

Error in bar(): asdasdf

Some kind of the stack flushing is needed. .Traceback<-NULL did not help

-- 
View this message in context: http://www.nabble.com/determining-a-parent-function-name-tf3843262.html#a10892608
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help_at_stat.math.ethz.ch 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.
Received on Thu 31 May 2007 - 12:30:39 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 31 May 2007 - 14:31:22 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.