Color of the line with gplot

David Bateman David.Bateman at motorola.com
Fri Apr 18 08:33:17 CDT 2008


Leandro Sales wrote:
> Hello,
>   I have this command:
>
> gplot ([DATA0(:,1), DATA0(:,5)]) title "Title1 (KBytes)",
> ([DATA0(:,1), DATA0(:,4)]) title "Title2 (KBytes)"
>
> I want the second line to be in blue color, how can I do this?
>
> Thank you,
> Leandro.
>   

Given the syntax above I presume you are using a 2.1.x version of Octave
as the gplot function changed its meaning in the 2.9.x tree to be
compatible with the corresponding Matlab function (ie. gplot plots a
graph  given the sparse adjacency matrix and the XY coordinates of the
points). I'd strongly suggest upgrading to Octave 3.0 and using the
matlab compatible syntax to set the colors.. Otherwise try modifying
your line to be something like

gplot ([DATA0(:,1), DATA0(:,5)]) with ls 1 title "Title1 (KBytes)",
([DATA0(:,1), DATA0(:,4)]) with ls 2 title "Title2 (KBytes)"

as gplot was just a function to connect directly to gnuplot, and so
follows the gnuplot syntax.

D.

-- 
David Bateman                                David.Bateman at motorola.com
Motorola Labs - Paris                        +33 1 69 35 48 04 (Ph) 
Parc Les Algorithmes, Commune de St Aubin    +33 6 72 01 06 33 (Mob) 
91193 Gif-Sur-Yvette FRANCE                  +33 1 69 35 77 01 (Fax) 

The information contained in this communication has been classified as: 

[x] General Business Information 
[ ] Motorola Internal Use Only 
[ ] Motorola Confidential Proprietary



More information about the Help-octave mailing list