help-octave
[Top][All Lists]
Advanced

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

Re: plotting in grace


From: Sergei Steshenko
Subject: Re: plotting in grace
Date: Thu, 4 Oct 2012 03:05:49 -0700 (PDT)

>________________________________
> From: asha g <address@hidden>
>To: c. <address@hidden> 
>Cc: "address@hidden" <address@hidden> 
>Sent: Thursday, October 4, 2012 11:44 AM
>Subject: Re: plotting in grace 
> 
>
>
>
> 
> 
>
>
>>  While googling, I found that octave can plot in both gnuplot and grace. 
>> 
>> For plotting in grace the data needs to be in ascii form and in columns. 
>> Now I can convert my binary data into ascii but it is not appearing as 
>> columns. When I tried something that was suggested earlier - it displays on 
>> the screen but does not save as a file. 
>> 
>> I would really appreciate help from someone who has experience doing this. 
>> 
>> The code I wrote is :
>> 
>> load catwalk X y
>> X= X', y = y';
>> save -mat-ascii catwalkascii X
y
>> 
>> If this does save as columns, then I can open it after typing xmgrace and 
>> import it. But as mine does not save as columns, it is proving to be 
>> difficult. 
>> 
>> Your help appreciated.
>> 
>> Thanks
>> 
>> Asha G 
>
>
>if you need to autput your data as columns of numbers you probably should be 
>using "dlmwrite" rather than "save"
>
>c.
>Just tried dimwrite  -mat-ascii catwalkascii X y
>
>Did not save either. 
>AG 
>
>
>
>_______________________________________________
>Help-octave mailing list
>address@hidden
>https://mailman.cae.wisc.edu/listinfo/help-octave
>
>


How about introducing a struct *say, 's'), assigning data to it and saving 
using 'save("-text" ...);' ?

Or even without the struct ?

Here is an example from what I'm doing - contents of a files saved using 
'save("-text" ...);':

"# Created by Octave 3.0.5, Fri Jul 08 00:11:48 2011 IDT <address@hidden>
# name: accumulated_spectra
# type: struct
# length: 3
# name: MM
# type: cell
# rows: 1
# columns: 1
# name: <cell-element>
# type: complex matrix
# rows: 1
# columns: 589825
 (-78.97504911431373,-3.673076946111337e-14) 
...
".

It _does_ preserve rows and columns info.

Regards,
  Sergei.




>


reply via email to

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