MathGroup Archive 1995

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

Search the Archive

Re: Point Labels on XY plot

  • Subject: [mg2658] Re: Point Labels on XY plot
  • From: ianc (Ian Collier)
  • Date: Thu, 30 Nov 1995 21:05:28 -0500
  • Approved:
  • Distribution: local
  • Newsgroups: wri.mathgroup
  • Organization: Wolfram Research, Inc.

In article <49je5k$53i at>, Jason
<jj8a at> wrote:

> Hi,
> I have a large 2D dataset and the points are dispersed all over.
> I would like to know if it is possible to plot these points with
> each data points drawn as the point labels, say data point #,
> rather than the usual way where all the points are drawn as a
> dot or a triangle etc...
> Thanks
> Jason
> mail replies to jj8a at or
> to this newsgroup

The following example replaces each point in a ListPlot with the
value of the x coordinate as text.

    data = Table[ {x, Sin[x]},{x, 0, 10}];

    gr1 = ListPlot[ data ]

    gr2 = gr1 /. Point[{x_,y_}] :> {
        Text[ x , {x, y}] }

    Show[ gr2 ]


I hope this helps.


Ian Collier
Technical Sales Support
Wolfram Research, Inc.
tel:(217)-398-0700     fax:(217)-398-0747      ianc at
Wolfram Research Home Page:   

  • Prev by Date: Re: X-FrontEnd crashes upon certain keystrokes
  • Previous by thread: Re: Point Labels on XY plot