MathGroup Archive 1993

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

Search the Archive

[no subject]

  • To: mathgroup at
  • From: deb at (David E. Burmaster)
  • Date: Wed, 10 Nov 93 13:53:51 -0500

SubjectL sort pairs

How can I sort pairs of values -- basing the sort on the first value
and then break ties on the second value in the pair.

Let's say I have n pairs on numbers in the following matrix

data = { {x1,y1}, .....{xi, yi}, .....{xn,yn} }

Using the Sort function in Mma, I can easily sort on the xi values, but
how can I do the secondary sort on the yi values??

Thank you for your help

David E. Burmaster
Alceon Corporation
Cambridge, MA 02238-2669

  • Prev by Date: BigSeriesExpansion
  • Next by Date: Mathematica/Freehand/Word problem
  • Previous by thread: BigSeriesExpansion
  • Next by thread: Mathematica/Freehand/Word problem