RE: Mesh in ListDensityPlot
- To: mathgroup at smc.vnet.net
- Subject: [mg42282] RE: [mg42265] Mesh in ListDensityPlot
- From: "David Park" <djmp at earthlink.net>
- Date: Fri, 27 Jun 2003 06:31:13 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
C.J., Here is an example with DensityPlot. We convert the output to Graphics and then use GridLines to get something equivalent to a subset of mesh lines. AxesFront -> True is used to get the grid lines to be in front of the density plot. In order to use AxesFront we have to import it from FilledPlot. (I always thought that AxesFront should be part of the regular 2D plot options.) Needs["Graphics`FilledPlot`"] Show[Graphics[DensityPlot[Sin[x]Sin[y], {x, -Pi, Pi}, {y, -Pi, Pi}, PlotPoints -> 100, Mesh -> False, DisplayFunction -> Identity]], GridLines -> Automatic, AxesFront -> True, ImageSize -> 500, DisplayFunction -> $DisplayFunction]; If you use DrawGraphics from my web site you don't have to convert to Graphics, turn the display off and on, or explicitly load FilledPlot, but you have to set the Frame and AspectRatio. You could easily add other elements to the plot. Needs["DrawGraphics`DrawingMaster`"] Draw2D[ {DensityDraw[Sin[x]Sin[y], {x, -Pi, Pi}, {y, -Pi, Pi}, PlotPoints -> 100, Mesh -> False]}, AspectRatio -> Automatic, Frame -> True, GridLines -> Automatic, AxesFront -> True, ImageSize -> 500]; David Park djmp at earthlink.net http://home.earthlink.net/~djmp/ From: Walden, CJ (Chris) [mailto:C.J.Walden at rl.ac.uk] To: mathgroup at smc.vnet.net Hi, I'm using ListDensityPlot to display a 2880 by 200 matrix of real values. If I set Mesh->True the result is completely dominated by black mesh lines. Does anyone know an easy way of displaying a subset of mesh lines? Thanks, Chris Walden -- ----------------------------------------------- Dr C.J. Walden [C.J.Walden at rl.ac.uk] Radio Communications Research Unit CCLRC Rutherford Appleton Laboratory Chilton, Didcot, OX11 0QX, UK Tel:+44-(0)1235-445601 Fax:+44-(0)1235-446140 -----------------------------------------------