MathGroup Archive 2005

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

Search the Archive

Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction

  • To: mathgroup at smc.vnet.net
  • Subject: [mg59692] Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction
  • From: Peter Pein <petsie at dordos.net>
  • Date: Thu, 18 Aug 2005 00:16:26 -0400 (EDT)
  • References: <ddurhk$ogh$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

hopeandjoyandpeace at hotmail.com schrieb:
> Combining a ListDensityPlot that uses a userdefined color function with
> a graphics 'looses' the userdefined colorfunction
> 
> for example
> 
> myArray=Table[Sin[x*y],{x,1,40},{y,1,40}]//N;
> Max[myArray]
> ListDensityPlot[myArray,Mesh-> False]
> 
> Show[ListDensityPlot[myArray,Mesh->False,ColorFunction->GrayLevel,ColorFunctionScaling->False],Graphics[{Blue,Thickness[0.01],Line[{{10,10},{20,20}}]}]]
> 
> 
> 
> Gives three density graphics but only one of them appears to uses the
> colorfunction of GrayLevel.
> 
> We have version 5.1
> How can I combine the image resulting when I define my own
> colorFunction with another graphics without the image changing the way
> it appears?
> 
> 
> Chris   
> ABCC Regina
> 
Hi Chris,

with the DrawGraphics package by David Park
(http://home.earthlink.net/~djmp/Mathematica.html) type:

Needs["DrawGraphics`DrawingMaster`"];
myArray = N[Table[Sin[x*y], {x, 1, 40}, {y, 1, 40}]];
ldp = Block[{$DisplayFunction = #1 & },
  ListDensityDraw[myArray, Mesh -> False]];
Show[Graphics[{ldp, Blue, Thickness[0.01], Line[{{10, 10}, {20, 20}}]}]]

-- 
Peter Pein
Berlin
http://people.freenet.de/Peter_Berlin/


  • Prev by Date: Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction
  • Next by Date: Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction
  • Previous by thread: Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction
  • Next by thread: Re: Combining a ListDensityPlot that uses a userdefined color function with a graphics 'looses' the userdefined colorfunction