How to plot a polar plot with different colors or how to overlay the plots?
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I have to have different colour for negative values and another one for positive values on the polar plot. The second option is to overlay two plots: one with negative and the other with positive values. My data is read from excel. I am adding a photo of a plot "Okres 3" to help you to see what it looks like. I would really apreciate your help. :)
0 commentaires
Réponses (1)
Star Strider
le 2 Avr 2021
Try something like this:
a = linspace(0, 2*pi); % Create Data
r = sin(a) + cos(2*a); % Create Data
ispos = r>0; % Positive ‘r’ Values = ‘true’
figure
polarplot(a(ispos), r(ispos), '-r')
hold on
polarplot(a(~ispos), r(~ispos), '-g')
hold off
.
0 commentaires
Voir également
Catégories
En savoir plus sur Polar Plots dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!