Info
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
Plotting axis in the correct position
조회 수: 1 (최근 30일)
이전 댓글 표시
Context: I am coding a scanner, and one of the features is to take an ROI scan atop a larger scan. The end result should be the ROI scan pasted on top of the original, in the place of the selected ROI. One thing I noticed is that the position property of the rectangle is relative to the axis, but the position property of the axis is relative to the figure (the axis range could be for example -12 to 12 in the x and -12 to 12 in the y, and [x,y] = ginput(1) gives the correct coordinate. I want an ROI image between 3 and 5 in the x, and 3 and 5 in the y. But using axes('Position', [3 3 2 2] does not give the correct position for the ROI, it's somewhere offscreen.)
댓글 수: 3
Adam Danz
2020년 6월 23일
Just to clear up some terminology, the data units are mm. The axis units are normalized. The ROI is plotted on the axes; it's a child of the axes. So you cannot place the axes within the ROI but you could place the ROI within the axes.
It sounds like you just need to use xlim() and ylim() and perhaps axis equal or axis tight.
답변 (0개)
이 질문은 마감되었습니다.
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!