Thread Subject: How to get the name of the caller?

Subject: How to get the name of the caller?

From: Mateusz

Date: 22 Nov, 2009 21:05:06

Message: 1 of 2

Hi,

I try to get the name of the caller function from the callee's side. Is it possible to do that in Matlab?

For instance:
function = funF()
myCall()
end

and then myCall prints out 'funF'.

Best,
M.M.

Subject: How to get the name of the caller?

From: ImageAnalyst

Date: 23 Nov, 2009 01:58:38

Message: 2 of 2

On Nov 22, 4:05 pm, "Mateusz " <m4li...@gmail.com> wrote:
> Hi,
>
> I try to get the name of the caller function from the callee's side. Is it possible to do that in Matlab?
>
> For instance:
> function = funF()
> myCall()
> end
>
> and then myCall prints out 'funF'.
>
> Best,
> M.M.

------------------------------------------------------------------------------------------------------
M.M.:
Yes. Look up documentation for the MATLAB built-in function called
"dbstack"
Regards,
ImageAnalyst

Tags for this Thread

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

rssFeed for this Thread

Contact us at files@mathworks.com