Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1995
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1995

[Date Index] [Thread Index] [Author Index]

Search the Archive

RE:Labeling Lines on a multiple plot

  • Subject: [mg2612] RE:[mg2159] Labeling Lines on a multiple plot
  • From: penny at edu-suu-scf.sc.suu.edu (Des Penny)
  • Date: Mon, 27 Nov 1995 21:36:27 -0500
  • Approved: usenet@wri.com
  • Distribution: local
  • Newsgroups: wri.mathgroup
  • Organization: Wolfram Research, Inc.

Hi:

I noticed that the code provided by Seth Chandler for labeling lines on a
plot had a bug in it.  Since it's such a nice piece of code and since no
one else has posted a correction, I thought I should do so.  The code is
identical to Seth's except for the bug correction and two slight
improvements.


flist={Function[x,x],Function[x,x+20Sin[x/10]],
        Function[x,x+30 Cos[x/20]]};

thelabels={"a","b","c"};


With[{rightEdge=-5},
        Plot[Evaluate[Through[flist[x],List]],{x,-50,rightEdge},
        PlotRange->All,
        Epilog->MapThread[Text[#2,{rightEdge,#1[rightEdge]},
        {-2,0}]&,{flist,thelabels}]]
]


Seth had "first" instead of "flist" in the last line.

Cheers,

Des Penny


==========================
Des Penny
Physical Science Dept.
Southern Utah University
Cedar City, UT 84720

VOICE: (801) 586-7708
FAX:    (801) 865-8051
e-mail: penny at suu.edu
==========================




  • Prev by Date: Re:Puzzle
  • Next by Date: Limiting mma caching (??)
  • Previous by thread: A simple equation, can Mathematica solve it?
  • Next by thread: RE:Labeling Lines on a multiple plot