How to put hat over a greek symbol express its value in legend of a plot?

11 次查看(过去 30 天)
I want to write expressions like alpha_0 cap(or hat)=0, alpha_0 cap(or hat)=1 and so on in legend of a plot.
Need to display aplha, with subsscript zero, with a hat, equate to a numerical value.
Kindly help me.

采纳的回答

madhan ravi
madhan ravi 2019-3-22
legend(sprintf('$\\hat{\\alpha}(0) = %d$',2),'Interpreter','latex')
% ^----- numeric value
  6 个评论
madhan ravi
madhan ravi 2019-3-22
Maybe it’s because of version: Try:
z= ['$\hat{\alpha}(0) =',num2str(2)','$'];
legend(z,'Interpreter','latex')

请先登录,再进行评论。

更多回答(1 个)

KSSV
KSSV 2019-3-22

类别

Help CenterFile Exchange 中查找有关 Labels and Annotations 的更多信息

产品


版本

R14SP2

Community Treasure Hunt

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

Start Hunting!

Translated by