Add a bar above a character in axis labels
30 views (last 30 days)
Show older comments
I am using the MATLAB figure editor where you can click on graph elements to edit them, eg. axis label etc. How do you add a bar above a character in axis labels, as in
to denote an average quantity for instance?
0 Comments
Accepted Answer
More Answers (1)
SUBAL BEURA
on 25 Nov 2024
Alternatively, From Figure window, you can open property editor for the whole diagram. Then find "Text" menu for axis. Edit the interpreter from "tex" to "latex". This method will also work if you want to change the interpreter for legends.
2 Comments
Walter Roberson
on 25 Nov 2024
You need to edit the String property as well, to insert the \bar{ } in the appropriate place.
Yassir
on 13 Mar 2025

I have tried the solution and it is working!
Many thanks to all of you.
One comment: I had to put the latex script within $ $ (example: $\bar{w}_c^{a,i}$).
See Also
Categories
Find more on Labels and Annotations 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!