MATLAB Answers


This question is closed. Reopen it to edit or answer.

angles to arrows representation

2 views (last 30 days)
Kalyan Samala
Kalyan Samala on 23 Nov 2020
Closed: MATLAB Answer Bot on 20 Aug 2021
I have an excel which contains angles and want to convent them into arrows representation.
Rik on 2 Aug 2021
Have a read here and here. It will greatly improve your chances of getting an answer.

Answers (2)

Bjorn Gustavsson
Bjorn Gustavsson on 2 Aug 2021
Arrow in 2-D:
r_from_origin = l*[cos(theta),sin(theta)];
Arrow in 3-D:
r_from_origin = l*[cos(phi)*sin(theta),sin(phi)*sin(theta),cos(theta)];
Functions to plot arrows neatly: arrow and arrow3

Image Analyst
Image Analyst on 2 Aug 2021
How about annotation()?
annotation(lineType,x,y) creates a line or arrow annotation extending between two points in the current figure. Specify lineType as 'line', 'arrow', 'doublearrow', or 'textarrow'. Specify x and y as two-element vectors of the form [x_begin x_end] and [y_begin y_end], respectively.
or the quiver() function?

Community Treasure Hunt

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

Start Hunting!

Translated by