help-octave
[Top][All Lists]
Advanced

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

Re: plotting a line label from matrix value


From: David DS Barnes
Subject: Re: plotting a line label from matrix value
Date: Mon, 17 Jul 2000 14:03:26 +0000

Teemu Ikonen wrote:
> 
> On Mon, 17 Jul 2000, David DS Barnes wrote:
> 
> > I have vectors X, Y, and matrix Z
> > and I want to
> >
> >       plot(X,Z(2,:),"<linelabel>")
> >
> > where <linelabel> is the value Y(2).
> 
> Does this work:
> 
> eval(sprintf("plot(X, Z(2,:), ';%d;')", Y(2)));
> 
> HTH

it certainly does, thanks,
BUT I need to plot many lines (ie length of vector)
and using this in a 
        for...
                plot...
        end; 
just gives me back a value "1" in the legend...

David
-- 
David DS Barnes
        mechanical eng,imperial college         |       t:0207 594 7181
        exhibition rd, london, sw7 2bx          |       f:0207 594 7127



-----------------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.che.wisc.edu/octave/octave.html
How to fund new projects:  http://www.che.wisc.edu/octave/funding.html
Subscription information:  http://www.che.wisc.edu/octave/archive.html
-----------------------------------------------------------------------



reply via email to

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