Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Unknown option PlotLegend in Plot

266 views
Skip to first unread message

yawnmoth

unread,
Oct 22, 2003, 4:13:17 AM10/22/03
to
entering the following commands into mathematica, as per the example,
result in an error for me...

<<Graphics`Legend`

Plot[{Sin[
theta], Cos[theta]}, {theta, 0, 2 Pi}, PlotStyle -> {RGBColor[1, 0,
0], RGBColor[0, 0, 1]}, PlotLegend -> {"Sin", "Cos"}]

here's the error:

Plot::optix : Unknown option PlotLegend in Plot

any ideas as to what's wrong, and how i may fix it? thanks!

David Park

unread,
Oct 23, 2003, 7:23:56 AM10/23/03
to
I didn't get that problem.

Are you certain you actually evaluated the

<<Graphics`Legend`

statement first? It has to be more than just in the notebook. It has to be
evaluated, and evaluated before the Plot statement is evaluated. If not,
then you will get the error message.

David Park
dj...@earthlink.net
http://home.earthlink.net/~djmp/

sean kim

unread,
Oct 23, 2003, 7:40:18 AM10/23/03
to
under Mathematica 5.0 for students, it works fine for me.

try it with the package preloaded before evaluating the cell.

sean

terr...@yahoo.com (yawnmoth) wrote in message news:<bn5e6t$6c2$1...@smc.vnet.net>...

Bob Walker

unread,
Oct 24, 2003, 5:00:44 AM10/24/03
to
I pasted your sample into my mm 4.1 on Linux and produced the expected
plots with legends. You don't mention any errors on reading the Legend
package, so I'm at a loss.

Good luck
bgw

0 new messages