pcolor and Data Cursor
1 次查看(过去 30 天)
显示 更早的评论
Hi,
I'd like to use the data cursor for pseudo color plots created with pcolor. I wonder how the arrow keys work in this case. If I press the arrow up/down key, the cursor moves one point up/down as I expect it. However, if I press the arrow lft/right keys the cursor seems to jump more diagonal than left/right as I would expect it.
Does anybody know the reason for this? Is there a way to overcome this behaviour and let the cursor move horizontically as well?
Jette
P.S. I'm working with R2010b.
0 个评论
回答(1 个)
Image Analyst
2012-9-24
Because the points in pcolor are not the colored tiles like you'd expect - they're the lines. Did you ever notice that you don't have a colored tile for each of your elements? If not, try this
m=magic(4);
pcolor(m); % Shows 3 by 3 array, not a 4x4 array.
I suggest you use image() or imshow() instead of pcolor unless you know for a fact that you want pcolor for some reason and are aware of its quirks.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Specifying Target for Graphics Output 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!