Axes Ticks
We can change where the ticks are marked on r and theta axes using the following functions.
Syntax:
rticks(<vector with tick values>)
thetaticks(<vectors with tick values in degrees>)
See the following example for understanding the above functions.
Example 2:
Matlab
% MATLAB code for axes ticks ax=polaraxes; r=linspace(-pi,pi); plot(ax,r,sin(r)) % Giving tick values rticks([0 .23 .5 1 ]) thetaticks([0 23 31 180 203 211]) |
Output:
Polar Axes Appearance and Behavior in MATLAB
Polar axes are coordinate axes where the two coordinate axes are r-axis for magnitude and theta-axis for angles. MATLAB has many functions to change the properties of these polar axes which we shall see throughout this article. In this article we shall see how to modify following properties of polar axes in MATLAB:
- Axes limits
- Axes ticks
- Axes tick labels
- R-axis tick angle
Let us see each of these with an example each.
Contact Us