MATLAB Answers

0

How do I get the title and label objects for an axes in MATLAB R2014b?

How do I get the title and label objects for an axes in MATLAB R2014b?

Products


Release

R2014b

1 Answer

Answer by MathWorks Support Team on 7 Oct 2014
 Accepted Answer

Starting in MATLAB R2014b, the text objects used for graph titles and axis labels are no longer children of the axes. Instead, use the Title, XLabel, YLabel, and ZLabel properties of the axes to get the associated text objects.
For example, get the text objects used for the title and x-axis label.
ax = gca;
t = ax.Title;
xl = ax.XLabel;

  0 Comments

Sign in to comment.