필터 지우기
필터 지우기

can someone tell my what does this do please..?? set(gca, 'XTick', [])

조회 수: 18 (최근 30일)
Jonathan
Jonathan 2013년 11월 27일
답변: Image Analyst 2013년 11월 27일
this is the code im using.
axes(handles.axes1); UP = imagesc(imread('UP.jpg')); set(gca, 'XTick',[]); set(gca, 'YTick',[]); set(gca, 'XColor','w'); set(gca, 'YColor','w'); axes(handles.axes2); DOWN = imagesc(imread('DOWN.jpg')); set(gca, 'XTick',[]); set(gca, 'YTick',[]); set(gca, 'XColor','w'); set(gca, 'YColor','w'); set(handles.axes1,'hittest','off'); set(UP,'hittest','off'); set(handles.axes2,'hittest','off'); set(DOWN,'hittest','off');
I don't know what is gca used for. And also I have this part of the code which I don't know what is used for either.
_handles.xy1 = round(get(handles.axes1,'Currentpoint')); x1 = handles.xy1(1,1); y1 = handles.xy1(1,2);_
Sorry if this is a very simple question. This is all new to me.

답변 (2개)

Jamie
Jamie 2013년 11월 27일
Hi Jonathan,
The command sets the axis tick labels for the current figure. gca gets the axis of the current figure (Get Current Axis) XTick and YTick are the properties in which MATLAB stores the location of the respective tick marks
  댓글 수: 1
Jamie
Jamie 2013년 11월 27일
편집: Jamie 2013년 11월 27일
handles.axes2 is simply an axis handle i.e.
axis_handle = findobj(gcf,'type','axis')

댓글을 달려면 로그인하십시오.


Image Analyst
Image Analyst 2013년 11월 27일
set(gca, 'XTick', []) removes the tick marks from the x axis.

카테고리

Help CenterFile Exchange에서 Axis Labels에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by