필터 지우기
필터 지우기

position of legend contour plot

조회 수: 3 (최근 30일)
Michiel
Michiel 2015년 3월 7일
댓글: Star Strider 2015년 3월 7일
I have a contour plot obtained via the function "contour", and it places the legend inside the figure. For regular plots there is this additional option to specify the location of the legend, however it does not seem to exist for the contour function. Is there anyway I can move it outside of the figure?

채택된 답변

Star Strider
Star Strider 2015년 3월 7일
편집: Star Strider 2015년 3월 7일
Use one of the ‘...outside’ 'Location' options:
M = magic(10);
figure(1)
contour(M)
legend('Data','Location','northeastoutside')
  댓글 수: 2
Michiel
Michiel 2015년 3월 7일
so much simpler than I thought
Star Strider
Star Strider 2015년 3월 7일
There are version differences, so the exact syntax can vary. This works with R2014b.

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

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by