File Exchange

image thumbnail

Comprehensive Polar Plots

version 1.0 (11.6 KB) by

Polar plots with handle graphics type parameter setting. Includes log radius support.

4.93333
15 Ratings

53 Downloads

Updated

View License

Attempts to bring comprehensive handle graphics capabilities to polar plots.

Comments and Ratings (19)

t abokhaled

very good function
thanks a lot

Hoi Wong

Hoi Wong (view profile)

Great tool. Can you add these two extra input arguments to all calls to text() in your code: 'Interpreter', 'tex'?

The reason is that by default, I use underscore a lot for variable names that are automatically generated on the plots, which make it natural for me to set(0,'DefaultTextInterpreter','none'); Since you used TeX syntax already, it doesn't hurt to force the 'Interpreter' to 'tex'.

Thanks!

Angelina Jay

Much more control than stock polar plot. Appreciate ability to plot negative radius values as well as easily control all visual aspects of the plot.

Galen

Galen (view profile)

Thank you for this significant improvement on the stock polar plotter.

I did find the handling of exceptions generated by plot() less helpful than propagating them back to the user and suggest the following patch. (For example, if Theta and Rho vectors are not the same size, rethrowing the exception makes that obvious, avoiding a debug session.)

--- orig/mmpolar.m 2014-02-12 14:11:10.000000000 -0600
+++ new/mmpolar.m 2016-03-08 16:37:30.000000000 -0600
@@ -288,15 +288,16 @@
       
 else % Hold is OFF
    
    try % the plot function should work now
       HAxes=newplot; % create axes
       D.HLines=plot(HAxes,varargin{:});
- catch
+ catch exception
       delete(gcf)
- local_error('Input Arguments Not Understood.')
+ % local_error('Input Arguments Not Understood.')
+ rethrow(exception)
    end
    HFig=ancestor(HAxes,'figure');
    D.NumLines=length(D.HLines); % get all data for storage
    D.TData=get(D.HLines,{'XData'});
    D.RData=get(D.HLines,{'YData'});
    D.LineColor=get(D.HLines,{'Color'});

Lukas Zednik

Great stuff.

Tarun Cousik

Hi,
 I am new to MATLAB ,I am trying to plot Antenna Gain Values(have negative values also) using this function.Can someone tell me the step by step procedure as to where I can input my data to get my graphs.
Thanks.

Ben Wu

Ben Wu (view profile)

good

Kenz

Kenz (view profile)

Andrew

Andrew (view profile)

very nice!

kamel kk

good work

Najim

Najim (view profile)

Will

Will (view profile)

nice

I have determined the source of the issue from my previous post...

When using this routine, you must set the RLimits appropriately. If not you might get a result that is difficult to interpret.

I am having an issue with the mmpolar function. For some reason it is displaying some of the data as a zero radius in the plot while the data never actually goes to zero. I have posted a question and provided examples in a Matlab question. That question can be found at:

http://www.mathworks.com/matlabcentral/answers/78159-strange-artifact-in-mmpolar

I am probably doing something silly, but this seems so simple that I can not see the error... Any feedback would be great!

All of that being said, thank you for the tool! It is fantastic and I have used it for a number of my analyses. Mathwork's should adopt this tool in future releases.

Jose Miguel

Duane,
This is an excellent piece of work, I've been using it since 2007. Thank you so much for sharing it.

I think, there might be a couple of little bugs with RLimit, both of them appear when RLimit is set in the call to mmpolar.

1) The RLimit max value seems to be working fine, but the RLimit min value doesn't. The plot results in a polar figure which is not centered at the RLimit min value but to a smaller value.

2) Under the same situation as 1 and when RTickValues are not set, an extra Rho axis line or sometimes just the label, appear outside the outer limit of Theta

Please feel free to contact at josemijauregui@hotmail.com

Thanks
Regards
Jose

Warwick

A comprehensive and well designed list of options. Minor improvement would be one simple example upfront - eg, a conventional geographic plot with North, East South & West labels. I'll be using this contributed function a lot.

Dan K

Dan K (view profile)

Duane,

Thank you for bringing this back to FEX... I've been using an old version of mmpolar, literally for years, and have found it tremendously useful.. I personally have found the built in polar function to be an impractical joke. Again, Thanks.

Hipstro Vert

nice work!

MATLAB Release
MATLAB 7 (R14)
Tags Add Tags

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video