contour plot does not match matrix contours
3 views (last 30 days)
Show older comments
Hello,
Assume I have the following matrix:
A=[1 2 3 4;2 3 4 5;3 4 5 6;4 5 6 7]
If I create the following plots:
figure; imagesc(A)
figure; contour(A)
The displayed contour lines do not line up with the constant values in the matrix. They are rotated 90 degrees from the imagesc plot. I have attached 2 pictures to show what I mean.
However, if the matrix is:
B = [1 2 3; 1 2 3; 1 2 3]
The two types of plots will match up.
Why does the contour plot apear to rotate the constant value lines when the gradient is angled?
Thanks
0 Comments
Answers (0)
See Also
Categories
Find more on Contour Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!