Uitable column name with symbols and subscripts

조회 수: 7 (최근 30일)
Yasmin Samy
Yasmin Samy 2019년 5월 12일
댓글: Walter Roberson 2019년 5월 12일
Hello,
I want to write the column name in my uitable as <reff,f> where eff,f are subscripts. I tried using html but for some reason adding the < ruins everything. Help?
PS I am using matlab R2016a

답변 (1개)

Walter Roberson
Walter Roberson 2019년 5월 12일
h = uitable('ColumnName', {'<html>r<sub>eff,f</sub>'})
  댓글 수: 4
Yasmin Samy
Yasmin Samy 2019년 5월 12일
This worked!! using the html code for the < symbol:
'<html>&lt r<sub>eff,f</sub> >'
its odd thougth that we can just use > and not its code and it works. Anyone know why this happens?
Walter Roberson
Walter Roberson 2019년 5월 12일
Sorry I had not realized the < > were intended to be literal.
> is accepted due to lax HTML parsing. A real HTML parser would have given an error .

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

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by