Re : Re: Mathematica 6.0 - Legend
- To: mathgroup at smc.vnet.net
- Subject: [mg76041] Re : [mg75999] Re: Mathematica 6.0 - Legend
- From: robert.pigeon at videotron.ca
- Date: Tue, 15 May 2007 04:54:37 -0400 (EDT)
- References: <f23p9k$ngj$1@smc.vnet.net> <200705140948.FAA26033@smc.vnet.net>
Thanks Daniel,
But I think it is really me... :) I have a mental block or an "old age" block but I can not make sense out of the documentaion on ShowLegend.... :(
Here is what I do.
Needs["PlotLegends`"]
a = Table[{i,i^2},{i,1,20}];
b = Table[{i,i^3},{i,1,20}];
ListLinePlot[a, PlotStyle -> {Red}]
(* I get a nice graph of my data *)
(* Here I would like to put a Legend showing the color and name of the plot *)
ShowLegend[
ListLinePlot[a, PlotStyle->{Red}],
Legend[{Red,"Line a"}]
]
And it does NOT work.... I get the following as output
ShowLegend[Picture of the plot, Legend[RGBColor[1,0,0],Line a}]]
I tried different ways, but to no avail...!
If I can get something, I want to put both plots a and b on the same graph and a legend showing the right color with the right name.
The actual plot I need to do is with 5 plots.
So please... HELP maybe by explaining step by step how to do it.
I really feel stupid not being able to make sense at something that should be simple. And I have to say that I've been using Mathematica since version 4. What a shame for me to be stuck like that! But, I think that MathGroup is there to help people like me here and laugh after they press the Return key ! :-)
Thanks again,
Robert
Robert Pigeon
- References:
- Re: Mathematica 6.0 - Legend
- From: dh <dh@metrohm.ch>
- Re: Mathematica 6.0 - Legend