Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #2477

Re: Points conditionnal Coloring

From Peter Pein <petsie@dordos.net>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: Points conditionnal Coloring
Date 2011-05-19 11:43 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <ir2vok$h2n$1@smc.vnet.net> (permalink)
References <iqtn7b$ik2$1@smc.vnet.net>

Show all headers | View raw


Am 17.05.2011 13:46, schrieb Louis-Alexandre:
> Hi,
>
> I am trying to plot some points, and color them according to a particular Value.
>
> dalist is of that kind : {{x1,y1,z1},{x2,y2,z2},... ,{xN, yN,zN}}
>
> So I need a simple 2D plot where the color of the point will depend on the z value.
>
> What I have :
>
> Graphics[{Hue[#3], Point[{#1, #2}]}&  @@@ dalist, Axes ->  {True, True}]
>
> Obviously this Hue[] is wrong.
>
> Many thanks fo any help you could provide,
>

Hi,

a little bit easier than Alexei's version:

Graphics[{Hue[#3], Point[{#1, #2}]} & @@@
   Transpose[MapAt[Rescale, Transpose[dalist], 3]],
  Axes -> {True, True}]

Peter

Back to comp.soft-sys.math.mathematica | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Points conditionnal Coloring Louis-Alexandre <laeh@nyu.edu> - 2011-05-17 11:46 +0000
  Re: Points conditionnal Coloring Peter Pein <petsie@dordos.net> - 2011-05-19 11:43 +0000

csiph-web