Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Rotating a Polar plot

146 views
Skip to first unread message

thomps

unread,
Nov 26, 2003, 9:31:16 AM11/26/03
to
I want to create a polar plot. But I want 0 degrees to be at the
top. I have tried to adjust the property 'view' and change it from [0
90] to [-90 90]. This rotates the plot as desired. However the plot
gets larger and my plot title overlays the degree labels. Try it
yourself.

figure(1);polar([0:360],ones(1,361)*5)
title('Default')
figure(2);polar([0:360],ones(1,361)*5)
set(gca,'view',[-90 90])
title('Rotated +90')

Does anyone why this happens or can suggest another way to rotate my
plot?

Thanks.

shawn gong

unread,
Nov 26, 2003, 11:32:26 AM11/26/03
to
In polar plot, everything is in Cartesian. Radial grids, spokes,
lables are transformed into Cartesian coordinates then drawn.
As result, the plot will get either larger or smaller depending on
your figure's aspect ratio.
Easy way:
1. experiment with
h2=figure('Position',[x y width height]);
2. use the "EDIT PLOT" cursor to drag the title out of the way.
3. if you don't like 2. try use "text(X,Y,'string')"
Hard way:
go to C:\Matlab13\toolbox\matlab\graph2d\polar.m
and edit/creat your polarplot code.

Shawn Gong

0 new messages