ADD LATeX legends and labels in MATLAB figures

87 visualizaciones (últimos 30 días)
Brave A
Brave A el 14 de Abr. de 2022
Comentada: Brave A el 14 de Abr. de 2022
I tried to add represent LateX sympol in Legen of figures.
legend({'Mean Energy Consumption', 'Mean of $u_{i}$ Value', ...
'Client Selection Frequency'}, ...
'location', 'northwest');
but the LateX is not working for Legend.

Respuesta aceptada

Riccardo Scorretti
Riccardo Scorretti el 14 de Abr. de 2022
Editada: Riccardo Scorretti el 14 de Abr. de 2022
Hi. You must add 'interpreter', 'latex':
figure
plot(rand(20, 3), 'o-');
legend({'Mean Energy Consumption', 'Mean of $u_{i}$ Value', ...
'Client Selection Frequency'}, ...
'location', 'northwest', ...
'interpreter', 'latex');

Más respuestas (0)

Categorías

Más información sobre Migrate GUIDE Apps en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by