Filter löschen
Filter löschen

Plot Zero on a Contour Plot

7 Ansichten (letzte 30 Tage)
Amanda
Amanda am 27 Nov. 2012
I'm plotting z values, 0 to 10, on a contour plot.
When I include data 1 or greater, I obtain a contour plot. Like the following:
longitude = [80 82 95]
latitude = [30 32 35]
temp = [1 4 6; 1 2 7; 3 5 7]
contourf(longitude,latitude,temp)
Now, I want to plot the ZERO VALUE also on the contour plot. While I was expecting one color representing the zero value, instead I obtained a white square.
longitude = [80 82 95]
latitude = [30 32 35]
temp = [0 0 0; 0 0 0; 0 0 0]
contourf(longitude,latitude,temp)
Amanda
  1 Kommentar
Doug Hull
Doug Hull am 27 Nov. 2012
Where on the original set of temp data is there an isoline of values equal to zero? The answer is nowhere! That is why you are not getting a zero value. In the second example, all the data is zero, so it is a degenerate problem.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Contour Plots finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by