[Top][All Lists]

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

save;load question

From: D Goel
Subject: save;load question
Date: Fri, 17 Dec 2004 15:14:40 -0500
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.2 (gnu/linux)


If a file contains merely data, no variable information, octave
handily allows one to load that data into a variable of choice: 


Very convenient.   But somehow, one can't save this way: 

Suppose program 1 generates a matrix, M, and needs to store it in a
file for later access by some other program: 


Program 2 does not know what program 1 calls the matrix, so it tries
the above loading trick: 


But this time, var is not the matrix any more.  It is now a structure.
This is because when saving, octave added the variable name "M" in
comments.  If there were no comments, this would work, but here it

So, how do i extract the actual value of the matrix inside the program
from this structure?  (Note that the program does not know that the
name of the variable is M).

Even better, is there a way to ask octave to save a variable, but
without the comments which store the variable-name as well?

Thanks very much. 


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]