MathGroup Archive 1996

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

Search the Archive

Re: Combining ListPlotVectorField and ListDensityPlot

  • To: mathgroup at
  • Subject: [mg3605] Re: Combining ListPlotVectorField and ListDensityPlot
  • From: Xah Lee <xah at>
  • Date: Thu, 28 Mar 1996 00:09:19 -0500
  • Organization: Best Internet Communications
  • Sender: owner-wri-mathgroup at

At 2:49 AM 96/3/20, Shane J Latham wrote:
>I want to superimpose a vector plot, say
>onto a density plot, say

What you need to do is to convert DensityGraphics returned by 
ListDensityPlot to a Graphics object, then both can be displayed 
together using Show.

Clear[ vectorArray,densityArray, gp1, gp2]

densityArray = Table[ Random[], {i,10}, {j,10}];
vectorArray = Table[ {Random[],Random[]}, {i,10}, {j,10}];

gp1 = ListDensityPlot[ densityArray]
gp2 = Graphics@ ListPlotVectorField[ vectorArray, Axes->True]

Show[{gp1, gp2}, AspectRatio->Automatic]

A very good book that answers most graphics related problems is
The Mathematica Graphics Guidebook by Cameron Smith & Nancy Blachman.
Addison Wesley 1995.

 xah at; 74631.731 at
 Quote of the day:
 Your nonsense is as good as mine.   --Metamathematician of metaland.


  • Prev by Date: Re: packages
  • Next by Date: Re: Coefficient in multivariate series
  • Previous by thread: Combining ListPlotVectorField and ListDensityPlot
  • Next by thread: EPSFile[] (was: Printing/TeX)