[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: accessing the calling environment from within a function

From: Paul Kienzle
Subject: Re: accessing the calling environment from within a function
Date: Thu, 9 Dec 2004 21:14:54 -0500


        - Paul

On Dec 8, 2004, at 11:16 AM, Paul Laub wrote:

Dear all,

How can I create a function able to access any or all of the
variables in the namespace (or scope) of the calling
environment. I'd like to do this without passing all
of the variables via the arg list and without explicitly
marking all variables as global.

One workaround, I suppose, is to use a script rather
than a function. But is there any way to invoke a
script in a function-like way, that is, with an
argument list? The best I can do is have the script
interactively request names of arguments using input().
However, I'd like to avoid such interactivity.

Currently I am using Octave 2.1.57 without the forge


Paul Laub

Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:
How to fund new projects:
Subscription information:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]