numColumns Property in legend

조회 수: 54 (최근 30일)
Roy Liao
Roy Liao 2018년 3월 23일
댓글: Golan Bel 2018년 10월 24일
I've got the need to arrange my legend into two columns. Luckily, I found matlab has the built-in method to do it.
However, as the image shows, even the example given by MATLAB does not work here. No matter I use the paired value set as legend({}, 'NumColumns', 2) or I use the dot notation as lgd = legend({}), and then lgd.NumColumns = 2.
I wonder what's the matter. Is this properties cut in recent version or is there something wrong?
Thanks a lot
  댓글 수: 3
Linda de Man
Linda de Man 2018년 3월 25일
i`m on R2017b version and it doesn`t work
Star Strider
Star Strider 2018년 3월 25일
It’s new in R2018a.
See Release Notes (link) under Graphics. Specifically: Add Legend to Graph (link).

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

답변 (1개)

Rik
Rik 2018년 3월 25일
For those not on R2018a, there is a FEX submission that should provide the same functionality: columnlegend
  댓글 수: 1
Golan Bel
Golan Bel 2018년 10월 24일
It does not provide the same functionality as it does not allow to set the font properties nor many other tweaks.

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

카테고리

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