help-octave
[Top][All Lists]
Advanced

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

RE: saving files without header


From: Hall, Benjamin
Subject: RE: saving files without header
Date: Tue, 3 May 2005 15:58:59 -0400

I always forget the transpose...try

fprintf( fid, fmt_str, dat' );

                          ^
                          |
--------------------------+



-----Original Message-----
From: fred [mailto:address@hidden
Sent: Tuesday, May 03, 2005 3:54 PM
To: Hall, Benjamin
Cc: 'Keith Goodman'; address@hidden
Subject: Re: saving files without header


Hall, Benjamin a écrit :
>
> a = [1:1000];
> b = a.^2;
> c = -a;
> 
> dat = [a' b' c'];
> fmt_str = repmat('%g ',[1 size(dat,2)]);
> fmt_str = [ fmt_str '\n' ];
> 
> fid = fopen('somefile.txt','wt');
> fprintf( fid, fmt_str, dat );
> fclose(fid);

Does not work for me :-(

It prints all a values, then b, then c, as previous ex.

Any idea ?


Thx.


-- 
Fred.



-------------------------------------------------------------
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
-------------------------------------------------------------



-------------------------------------------------------------
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]