필터 지우기
필터 지우기

Setting plot legend properties

조회 수: 9 (최근 30일)
Jared
Jared 2013년 2월 20일
댓글: Xel Ch 2018년 8월 14일
Is it possible to specify the size of the colored dot in the legend? I have my data points plotted as dots, and when zoomed out, the dots are very small, and the dots in the legend are very small. When I zoom in, the dots in the legend increase in size. Can I specify this size as a fixed value? Can I set the type of "dot" or is it based on what the data is? I would like to create a big colored square for each data series, like the legend in a bar plot.
  댓글 수: 1
Xel Ch
Xel Ch 2018년 8월 14일
Hi Jared, I am looking into a similar issue, and wondering if you ever found an answer to this? Thanks!

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

답변 (1개)

Youssef  Khmou
Youssef Khmou 2013년 2월 20일
편집: Youssef Khmou 2013년 2월 20일
Jared,
try to increase the Marker size first :
plot(data,'.',...,'MakerSize',3.65) % x3.65 as example
Line Style specifier :
- Solid line (default)
-- Dashed line
: Dotted line
-. Dash-dot line
try : %doc plot%
  댓글 수: 2
Jared
Jared 2013년 2월 20일
I don't want to change the size of the markers on the actual plot, I have those set as I need them. I want to change the size of the markers in the legend only. Is that possible?
Youssef  Khmou
Youssef Khmou 2013년 2월 20일
maybe,i have no idea about Markers , anyway you can change the FontSize and the LineWidth :
plot(rand(100,1),'.');
h=legend(' Test');
set(h,'FontSize',10) %
set(h,'LineWidth',2)
get(h)

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

카테고리

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