I wonder what is the difference between annotation()
and text()
functions in Matlab? In what cases are one of them preferred over the other?
TEXT positions text in relation to axes. In contrast, ANNOTATION position is figure-related. ANNOTATION can put on figure not only text, but lines, shapes, arrows, etc. Consequently, TEXT takes axes handles as an argument (or gca for current axes), and ANNOTATION takes figure handles (or gcf for current figure).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With