Change circular histogram scale
Afficher commentaires plus anciens
Hi,
I plot couple of circular histograms using circ_plot from Circular Statistics Toolbox for Matlab ( http://www.jstatsoft.org/v31/i10) and I would like to set the same histogram scale for different plots. Is it possible?
Thanks
Réponses (1)
Grzegorz Knor
le 6 Sep 2011
circ_plot uses standard matlab rose function. Unfortunatelly there is no 'rlim' (something like xlim) property. You can fix it by simple trick, just plot polar(0,rmax,'-k') before you use circ_plot, where rmax is something like 'rlim':
rmax = .1;
% Examples:
figure
polar(0,rmax,'-k')
hold on
alpha = randn(60,1)*360;
circ_plot(alpha,'hist',[],12,true,true)
hold off
figure
polar(0,rmax,'-k')
hold on
alpha = randn(120,1)*360;
circ_plot(alpha,'hist',[],20,true,true,'linewidth',2,'color','r')
hold off
figure
polar(0,rmax,'-k')
hold on
alpha = randn(160,1)*360;
circ_plot(alpha,'hist',[],20,true,true,'linewidth',2,'color','r')
hold off
Catégories
En savoir plus sur Histograms dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!