[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Using a string variable as a filename #2
From: |
William Krekeler |
Subject: |
RE: Using a string variable as a filename #2 |
Date: |
Tue, 8 Nov 2011 19:42:23 +0000 |
Al,
Glad I could help.
To do what you want to do you must use the command call version with
parenthesis. They are handled the same way as I believe that print will also
fail if you try to do the same thing, ie call a quantity as a string variable
without using the parenthesis version. I am not sure why some of the older
functions use a different structure in the help interface that implies
parenthesis should not be used. FYI, both octave and matlab have this problem
and it is confusing to those that do not know. Try:
A = 1:10;
filename3 = 'some_text';
save( filename3, '-ascii', A);
William Krekeler