Plotting Image arrays with Imagesc flips them vertically.
조회 수: 3 (최근 30일)
이전 댓글 표시
I have an image contained in an array with (1,1) being in the top left corner. When using imagesc the image flips vertically and the y axis plots from 0-num starting from the bottom. Is there a way I can prevent the image from flipping and have the y-axis count from the top left down?
댓글 수: 0
채택된 답변
Image Analyst
2016년 7월 28일
It should work correctly. If it doesn't then perhaps the direction got reversed. You can either put
cla reset;
before you call imagesc(), or reverse the direction afterwards
axis ij;
댓글 수: 0
추가 답변 (1개)
Walter Roberson
2016년 7월 28일
"axis ydirection controls the placement of the coordinate system origin and the direction of increasing y values. Set ydirection to ij to place the origin at the upper left corner of the axes. The y values increase from top to bottom. Set ydirection to xy to place the origin at the lower left corner. The y values increase from bottom to top. This is the default value."
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Annotations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!