help-octave
[Top][All Lists]
Advanced

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

assign list of variables to a string array?


From: Thorsten Meyer
Subject: assign list of variables to a string array?
Date: Wed, 19 Nov 2003 19:11:42 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3.1) Gecko/20030425

Hi,

Is there a way to assign the names of the user defined variables to a string array?
I tried
        a = who;
but that does not work: who has no return value.

I need a function that loads an octave data file into a structure variable. E.g., if the file contains three variables a,b,c, they should be assigned to data.a, data.b, data.c. As a workaround, I have used an external perl filter, that scans the data file and returns a list of variable names, which I can then feed into an appropriate eval command. But I would appreciate it very much if there was a solution within octave (calling perl is quite slow on my system).

thanks,

Thorsten




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

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

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