Contour plotting with x,y,z data
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello, I am in need of plotting contour of the data I have. I have values for x,y,z axis. Now I am not having any relation between these axes.
How can I plot contour of it? I checked Matlab help and everywhere they have mentioned a relation z axis with x and Y which I don't have!
4 Kommentare
Walter Roberson
am 6 Mai 2015
Do you mean that you have scattered input? Vectors of X, Y, and Z rather than rectangular grids?
Antworten (1)
Walter Roberson
am 6 Mai 2015
2 Kommentare
Bjorn Gustavsson
am 22 Mai 2015
Bearbeitet: Bjorn Gustavsson
am 22 Mai 2015
Yes useful. Download function in link, then try this example:
x = randn(312,1);
y = randn(312,1);
tri = delaunay(x,y);
z = exp(-x.^2/0.5^2-abs(y.^3)/0.3^3);
[c,h] = tricontour(tri,x,y,z,7);
That is how matlab can do this job.
If your data are significantly different, for example way fewer points or some special geometry that makes other solutions better, we cant tell without more information.
HTH
Siehe auch
Kategorien
Mehr zu Surface and Mesh 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!