필터 지우기
필터 지우기

how to change the values on the polar axis?

조회 수: 2 (최근 30일)
bsd
bsd 2011년 7월 11일
Dear sir/madam,
I am plotting antenna radiation patterns using matlab, using polar command. When I plot the radiation pattern using the polar command the polar axis shows [0 to 360] degrees. This is good for azimuthal angle. But for the elevation angle I need the polar axis to be shown as [0 to 180] on one side and [0 to -180] on the other side. How can I do this in matlab? Looking forward for your reply.
Thanking you, BSD

답변 (1개)

Walter Roberson
Walter Roberson 2011년 7월 12일
polar(....);
ph = allchild(gca); %hidden children!!
Now, ph(6:17) are handles of text() objects whose String property is an angle. The correspondences are:
6: 0, 7: 180, 8: 330, 9: 150, 10: 300, 11: 120, 12: 270, 13: 90, 14: 240, 15: 60, 16: 210, 17: 30
Thus you would, for example, set(ph(8),'String','-30')
If you want the -180 to appear, you are going to have to text() a new label in to place. You could get() the Position of ph(7), fudge it a bit, and text() the '-180' in to place beside the '180'

카테고리

Help CenterFile Exchange에서 Polar Plots에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by