Using AMS in figure anotation with LaTeX interpreter
5 views (last 30 days)
Show older comments
I've been searching for some time to simplify a figure legend and for this I need to make Matlab interpret LaTeX AMS formulas.
In LaTeX, the commands "\textcolor{red}{$ \blacksquare$}" or $\triangledown$ are displayed but Matlax don't understand them, even when the interpreter is set to latex.
An example code is : figure annotation('textbox',[0.2 0.2 0.4 0.4],... 'Interpreter','latex',... 'String',{'Case 1: \textcolor{blue}{$\blacksquare$} meas 1',' \textcolo{red}{$\blacklozenge$} meas 2','Case 2: $\square$ meas 1',' $\triangledown$ meas 2'});
The \textcolor can probably be replaced by setting by hand the colour but the AMS commands ($\blacksquare$) aren't understood by Matlab anyway.
Which command should I be using so that Matlab interpret AMS formulas?
Thank you,
Michael
0 Comments
Accepted Answer
Daniel Shub
on 17 Jul 2012
It cannot be done. The MATLAB LaTeX interpreter is not a full fledged LaTeX distribution. As you haven't, and cannot, load the ams* packages, you cannot use the functionality. If you are including the output in LaTeX, you could use something like LaPrint.
0 Comments
More Answers (1)
See Also
Categories
Find more on Printing and Saving in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!