MATLAB: Clarification regarding text in figure

figureplottingtext;

I have a quick question:
I was trying to get text on a figure, kindly consider the following:
t = linspace(0,2*pi,50);
y = sin(t);
plot(t,y)
Following works fine
text(2, 0, '$\theta$', 'interpreter','latex','Position', [0.1 0.8], 'Units', 'normalized' );
But not this
text('$\theta$', 'interpreter','latex','Position', [0.1 0.8], 'Units', 'normalized' );
Why? Can someone please explain.
Thanks

Best Answer

>> help text
text Text annotation.
text(X,Y,'string') adds the text in the quotes to location (X,Y)...
Note the X,Y inputs are not documented as optional
Related Question