How can I remove the grid lines and labels from a polar plot within MATLAB?
4 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I have created a plot with the POLAR function from which I want to remove the grid lines and labels. However, changing the axes' properties does not affect the polar plot.
Risposta accettata
MathWorks Support Team
il 31 Ago 2010
There are no actual polar axes in MATLAB 6.5.1 (R13SP1) and earlier versions. The polar plot is created with a patch object representing the background, and multiple line and text objects used to create the grid lines and labels, respectively. These objects exist in an axes, whose "Visible" property has been set to "off".
You can remove the labels and grid lines from a polar plot by locating their handles with the FINDALL function, and using the DELETE function to remove them.
% create the polar plot, and store the line's handle
p = polar((0:99)*pi/100, (0:99)/100);
% find all of the lines in the polar plot
h = findall(gcf,'type','line');
% remove the handle for the polar plot line from the array
h(h == p) = [];
% delete all other lines
delete(h);
% find all of the text objects in the polar plot
t = findall(gcf,'type','text');
% delete the text objects
delete(t);
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Polar Plots in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!