how to add the solar symbol as a subscript on the y-axis label?

2 views (last 30 days)
I am plotting a figure where on the Y axis-label I need the solar symbol. the label would require M_{solar symbol}. I can produce the solar symbol in the label using the following lines of code. But I cannot do "solar symbol" as a subscript. here is my code.
solar = char(9737)
ylabel( ['10^{-6} M',solar, 'Year^{-1}'], 'FontSize',14,'FontWeight','bold')
any suggestions, please ?
  3 Comments
Walter Roberson
Walter Roberson on 11 Sep 2016
Which MATLAB version are you using? Unicode symbols are not expected to work until R2014b or later.
Walter Roberson
Walter Roberson on 11 Sep 2016
The LaTeX symbol name is \astrosun from wasysym which is a package not normally included in MATLAB. There are apparently some ways to add LaTeX packages but the ways are not user-friendly.

Sign in to comment.

Answers (0)

Categories

Find more on Solar Power in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!