Re: How do you create a ListContourPlot from a mesh of non-equally spaced real numbers?

• To: mathgroup at smc.vnet.net
• Subject: [mg25801] Re: How do you create a ListContourPlot from a mesh of non-equally spaced real numbers?
• From: leko at ix.netcom.com (J. Leko)
• Date: Wed, 25 Oct 2000 03:53:55 -0400 (EDT)
• References: <8se9tu\$6qj@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Oliver,

It sounds like what you want can be done using the ExtendGraphics package
command ListContourPlot by Tom Wickham-Jones. This package modifies the
functionality of the ListContourPlot command to accept {x, y, z} points,
instead of simply plotting z-values versus array index. It can be found in
the MathSource library at
http://www.mathsource.com/Content/Enhancements/Graphics/3D/0208-976.

Also included in this package is another command called LabelContourLines,
which  will tag contour lines with their values. It might be helpful to
you.

BTW, all of these commands are explained in TWJ's book, Mathematica
Graphics (1994).

Hope this helps!

J.

In article <8se9tu\$6qj at smc.vnet.net>, Oliver Schwindt
<mccpgos2 at dirac.phy.umist.ac.uk> wrote:

> Hello,
>
> I have a problem with performing a ListContourPlot with irregular data.
My data can be written in such away, that I have a rectangular grid
(actually only almost, but that can be rewritten to be exact), with
non-integer values x1,x2,x3...   by y1,y2,y3... but they are not equally
spaced! This means I can not use the array index numbers which it uses to
plot by default. I would also like to have the proper labels of the values
of x and y for the axes, and not the array index number. Basically, I
would like a graph of 'ListSurfacePlot3D' which is flattened to be
contours in two dimensions instead of a 3D surface.
>
> An example form of the data is:
>
> {{{0.79690240000000001`,2.`,17.1591599999999999`},{0.797639499999999923`,
>       1.42857142857142864`,17.2544800000000009`},{0.798226699999999933`,1.`,
>       16.8197699999999983`},{0.798846900000000026`,0.5`,
>       16.9753900000000008`},{0.799160899999999951`,0.25`,
>       16.9719699999999988`},{0.799315400000000053`,0.125`,
>       17.0197499999999983`},{0.799447600000000058`,0.02`,
>       17.0165599999999983`},{0.799472500000000074`,1.`*^-9,
>       17.0194900000000011`}},{{0.317149899999999984`,2.`,
>       9.43279199999999917`},{0.317928500000000013`,1.42857142857142864`,
>       9.37374200000000001`},{0.31848749999999999`,1.`,9.2903260000000003`},{
>       0.319141300000000027`,0.5`,9.19831600000000015`},{0.31946690000000002`,
>       0.25`,9.23090400000000066`},{0.319610200000000022`,0.125`,
>       9.24348900000000028`},{0.319746700000000005`,0.02`,
>       9.25857500000000044`},{0.319770500000000001`,1.`*^-9,
>       9.24925200000000025`}},{{0.196953999999999993`,2.`,
>       9.44644699999999915`},{0.197928099999999993`,1.42857142857142864`,
>       8.49427200000000048`},{0.198513600000000032`,1.`,8.20476700000000036`},{
>       0.1991654999999Untitled-Untitled-1,0.5`,8.19703900000000018`},{
>       0.199479299999999994`,0.25`,8.22965699999999955`},{
>       0.199638299999999979`,0.125`,8.22096499999999963`},{
>       0.199772000000000016`,0.02`,8.21111900000000005`},{
>       0.199799499999999987`,1.`*^-9,8.21094300000000032`}},{{
>       0.143261300000000009`,2.`,15},{0.143261300000000009`,
>       1.42857142857142864`,8.54252100000000069`},{0.143915199999999998`,1.`,
>       8.07665000000000077`},{0.144603199999999976`,0.5`,7.925319`},{
>       0.144903100000000017`,0.25`,8.15918800000000032`},{
>       0.145058700000000007`,0.125`,8.03011099999999977`},{
>       0.145192100000000001`,0.02`,8.04480200000000067`},{
>       0.145216399999999996`,1.`*^-9,8.04446399999999961`}},{{
>       0.11267069999999999`,2.`,15},{0.11267069999999999`,1.42857142857142864`,
>       15},{0.11267069999999999`,1.`,8.19419800000000009`},{
>       0.113367499999999998`,0.5`,7.96541500000000013`},{0.113678699999999999`,
>       0.25`,7.9688150000000002`},{0.113841999999999998`,0.125`,
>       7.98598500000000033`},{0.113957700000000006`,0.02`,
>       8.02624800000000071`},{0.11398919999999999`,1.`*^-9,
>       8.02544100000000071`}},{{0.0931426899999999946`,2.`,Untitled-115},{
>       0.0931426899999999946`,1.42857142857142864`,15},{0.0924467899999999964`,
>       1.`,8.24917699999999953`},{0.0931426899999999946`,0.5`,
>       8.02454900000000037`},{0.0934541700000000119`,0.25`,
>       7.97669199999999989`},{0.0936062900000000119`,0.125`,
>       8.00101899999999943`},{0.093726439999999993`,0.02`,
>       8.04149899999999995`},{0.0937570000000000014`,1.`*^-9,
>       8.03143599999999935`}},{{0.078921720000000004`,2.`,15},{
>       0.078921720000000004`,1.42857142857142864`,15},{0.078921720000000004`,
>       1.`,15},{0.078921720000000004`,0.5`,8.03793499999999916`},{
>       0.0792579499999999903`,0.25`,7.99941299999999966`},{
>       0.0794220099999999984`,0.125`,8.01981400000000022`},{
>       0.0795468500000000044`,0.02`,8.04646600000000056`},{
>       0.0795730500000000073`,1.`*^-9,8.04301599999999972`}},{{
>       0.0684152600000000088`,2.`,15},{0.0684152600000000088`,
>       1.42857142857142864`,15},{0.0684152600000000088`,1.`,15},{
>       0.0684152600000000088`,0.5`,8.10565399999999947`},{
>       0.0687634700000000087`,0.25`,8.01780899999999974`},{
>       0.0689107899999999951`,0.125`,8.04132899999999928`},{
>       0.069044919999999994`,0.02`,8.05345600000000061`},{
>       0.0690702700000000024`,1.`*^-9,8.05733900000000069`}},{{
>       0.0606491800000000047`,2.`,15},{0.0606491800000000047`,
>       1.42857142857142864`,15},{0.0606491800000000047`,1.`,15},{
>       0.0606491800000000047`,0.5`,8.29358200000000067`},{
>       0.0606491800000000047`,0.25`,8.05089300000000029`},{
>       0.0608114799999999977`,0.125`,8.06020299999999956`},{
>       0.0609501199999999965`,0.02`,8.06786400000000014`},{
>       0.060973670000000002`,1.`*^-9,8.07410499999999942`}}}
>
>
> and this can be viewed by:
>
>
ListSurfacePlot3D[w,BoxRatios->{1,1,1},Axes->True,ViewPoint->{-0.5,-2,1},PlotRange->{{0,0.45},{0,2},{7.9,15}}]
>