pcolor not showing edge of matrix

2 views (last 30 days)
I am plotting a matrix using the following:
figure(1);
pcolor(VX);
shading flat;
colorbar;
xlabel('x, km');
ylabel('y, km');
axis ij image ;
title('vx1');
It looks how I want, but for some reason it is not showing the right and bottom edges of the matrix VX. If I replot the matrix using 'shading interp', these edges are clearly interpolated into the graphed area, but with flat shading they are cut off.
What is wrong?
Also, for some reason the axes label the edges of the pixel and not the pixels themselves (which represent the actual matrix values), which seems erroneous for this kind of plot. What is going on there?

Accepted Answer

Mischa Kim
Mischa Kim on 27 Feb 2014
Christopher, this answer should help.

More Answers (0)

Products

Community Treasure Hunt

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

Start Hunting!