File Exchange

image thumbnail

CircHist - circular / polar / angle histogram

version 1.3.0.2 (1.21 MB) by Frederick Zittrell
Creates circular / polar / angle histograms

16 Downloads

Updated 08 May 2019

GitHub view license on GitHub

CircHist creates circular (polar) histograms from angle data, either distribution data or already-binned data. Works with circular and axial (bimodal) data. Circular statistics (average angle, 95 % confidence interval, resultant vector length, Rayleigh test of uniformity and circular-linear correlation) are automatically calculated using the CircStat Toolbox (https://github.com/circstat/circstat-matlab) and are graphically included. All visual properties can be dynamically adjusted; see @CircHist/html/exampleCircHist.html for usage examples. This function is conceptually similar to MATLAB's ROSE and POLARHISTOGRAM functions, but differs from them in several respects:
- Instead of plotting the histogram bins as wedges, they are plotted as straight bars.
- The histogram bins can have error bars.
- The radius-axis scale is shown as a straight scale next to the plot.
- Circular statistics are automatically computed.
- Arrows with specific direction and length can be overlayed.

Cite As

Frederick Zittrell (2019). CircHist - circular / polar / angle histogram (https://www.github.com/zifredder/CircHist), GitHub. Retrieved .

Frederick Zittrell (2019). CircHist (https://www.github.com/zifredder/CircHist), GitHub. Retrieved March 27, 2019.

Comments and Ratings (5)

Thank you for your reply -- I checked (hopefully) all functions that are called by the code and determined the minimum MATLAB version required: R2017a.
It would be possible to reduce it to R2016a, where POLARAXES was introduced, but this is a fundamental part of the code, so I cannot provide a fix -- sorry for the inconvenience.

requires polaraxes that I don't have

The function THETATICKFORMAT was introduced in MATLAB R2016b, is it possible that you use an older version than this?
In any case, this function is just a shortcut to change the respective axes-property, so I might just change my code to refer to this property directly, then older MATLAB versions without THETATICKFORMAT will be supported.

There is an error when running this:
Undefined function or variable 'thetatickformat'.

Error in CircHist (line 624)
thetatickformat(polarAxs,'degrees');

Error in exampleCircHist (line 9)
obj1 = CircHist(sDist,nBins);

Updates

1.3.0.2

Update required MATLAB version.

1.3.0.1

Update description

1.3.0.0

Files are now linked to GitHub repository.

1.3.0.0

- Changed input parsing: Name-Value pairs that had an 'on'/'off' switch now have a boolean switch. EDGES input argument is now optional.
- Added functionSignatures.json.
- Minor bug fixes regarding missing target-handle in some calls.

1.2.2.0

Fixed bug in SET.FONTSIZE during object construction.

1.2.1.0

Minor changes in documentation and description.

1.2.0.0

Introduction of DRAWARROW, which enables adding arrows with a specified direction and length.

1.1.2.0

Minor addition to previous compatibility-improvement.

1.1.1.0

Minor compatibility update.

1.1.0.0

Minor bugfix in method setRLim.

MATLAB Release Compatibility
Created with R2019a
Compatible with R2017a to any release
Platform Compatibility
Windows macOS Linux

@CircHist