## Documentation Center |

Plot arrows emanating from origin

`compass(U,V)compass(Z)compass(...,LineSpec)compass(axes_handle,...)h = compass(...)`

A compass graph displays the vectors with components `(U,V)` as
arrows emanating from the origin. `U`, `V`,
and `Z` are in Cartesian coordinates and plotted
on a circular grid.

`compass(U,V)` displays a
compass graph having *n* arrows, where *n* is
the number of elements in `U` or `V`.
The location of the base of each arrow is the origin. The location
of the tip of each arrow is a point relative to the base and determined
by `[U(i)`,`V(i)]`.

`compass(Z)` displays a compass
graph having *n* arrows, where *n* is
the number of elements in `Z`. The location of the
base of each arrow is the origin. The location of the tip of each
arrow is relative to the base as determined by the real and imaginary
components of `Z`. This syntax is equivalent to `compass(real(Z),imag(Z))`.

`compass(...,LineSpec)` draws
a compass graph using the line type, marker symbol, and color specified
by `LineSpec`.

`compass(axes_handle,...)` plots
into the axes with the handle `axes_handle` instead
of into the current axes (`gca`).

Was this topic helpful?