Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Given a datetime plot, how to i insert a text in the plot?

1 Ansicht (letzte 30 Tage)
yashvin
yashvin am 2 Jul. 2015
Geschlossen: Stephen23 am 2 Jul. 2015
Hi I have a datetime plot. I want to insert a text in a specific part of the plot. Since my xaxis is no longer an integer, I am getting error while using "text".
How can i solve it?
x_p=time_select_20000(out_select(i,2):out_select(i,3));% datetime array
y_p=Alt_select_20000(out_select(i,2):out_select(i,3));%integer
plot(x_p,y_p)
i=1;
a=time_select_20000(out_select(i,2));%datetime point
b=Alt_select_20000(out_select(i,2));%integer point
n=10
str1 = sprintf('Flight level : %d',n)
text(a,b,str1)
I am getting this error
Error using text
First two or three arguments must be numeric doubles.
How do i change the datetime to satisfy this?

Antworten (0)

Diese Frage ist geschlossen.

Community Treasure Hunt

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

Start Hunting!

Translated by