Can You Change Domain in ListContourPlot?
- To: mathgroup@smc.vnet.net
- Subject: [mg11496] Can You Change Domain in ListContourPlot?
- From: "Chris Farr" <farr@brown.edu>
- Date: Fri, 13 Mar 1998 12:21:43 -0500
Consider the following 2-D matrix. { {6.4,1.9},{5.25,15.6} }. When I do a ListContourPlot, the domain on the horizontal axis goes from 1 to 2. On the vertical axis, the domain also ranges from 1 to 2. Thus, mathematica assumes the domain is juts the values' position in the matrix. What if the above is not really the domain? For example, let's say that (X=149, Y=15) yielded a value of 6.4. Mathematica thinks that (X=1,Y=1) yielded this value. It seems that ListContourPlot only accepts a matrix of values, not the domain. I tried to put in the below: ListContourPlot[{ {149,15,6.4},etc..}], but to no avail. So, that's my question, but I would like to avoid the following solution to this problem, however: Create an interpolating object via ListInterpolation which transforms the domain from the "position in the matrix" domain to the actual domain. The command is the following: ListInterpolation[matrix values,{xdomain,ydomain}] Then, one could do a ContourPlot (not a ListContourPlot as it is now a continuous thing) on the interpolating object. This works, but my ultimate goal is to extract contour lines. The interpolating business causes some imprecision I would like to avoid. Thanks in advance, Chris Farr