Alternative box plot

Draw a box plot with various display options

https://github.com/IoSR-Surrey/MatlabToolbox

Download
Download

You are now following this Submission

Editor's Note: This file was selected as MATLAB Central Pick of the Week

Cite As

Christopher Hummersone (2026). Alternative box plot (https://github.com/IoSR-Surrey/MatlabToolbox), GitHub. Retrieved .

Acknowledgements

Inspired by: notBoxPlot, Hierarchically grouped boxplot

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
3.2.1

Function now natively supports sub-groups, handles NaNs more robustly, and returns sample size(s). A few other minor tweaks and doc changes.

Download
3.1.0

Added 'theme' property to allow multiple display properties to be changed simultaneously. Various bug fixes.

Download
3.0.2

More bug fixes. Forced legend alpha to match box alpha.

Download
3.0.1

Added ability to specify colors as a colormap function. Changed some size properties to no longer be specifiable for each group. Bug fixes.

Download
3.0.0

Re-implemented function as a class (with a new name). Added property to automate construction of a legend.

Download
2.0.8

Added meanSize property.

Download
2.0.7

Corrected calculation of mean when data include NaN. Updated picture.

Download
2.0.6

Added options for displaying the means.

Download
2.0.5

Added trap for MarkerEdgeAlpha (scatterAlpha), which older versions of Matlab do not support.

Download
2.0.4

Added layer and transparency options.

Download
2.0.3

Fixed automatic placement of boxes.

Download
2.0.2

Corrected bug where x offset was erroneous if y was not hierarchical.

Download
2.0.1

Small tweaks to improve robustness.

Download
2.0.0

Numerous changes to interface in order to support multidimensional data and improve hierarchical data labelling. Added scaleWidth option to scale box widths according to sample size.

Download
1.6.3

Added x-shaping to outliers and tweaked offset distribution.

Download
1.6.2

Added x shaping for overlayed scatter plots whereby the random x offset is related to the data distribution. Fixed bug whereby xSeparator handle would be sought even if xSeparator was not specified.

Download
1.6.1

Shuffled a few things around so that the creation order defines the layering, rather than relying on uistack(). Added linkprop() and listener to keep axes in sync and to change xseparator if ylim changes.

Download
1.6.0

Forgot to include tab2box.

Download
1.5.1

Fixed bug where x is a cell array of strings.

Download
1.5.0

Remove NaN from x data (and corresponding y data).

Download
1.4.1

Updated documentation.

Download
1.4.0

Improved robustness to small or empty samples. Add tab2box function for arranging tabular into the format accepted by box_plot.

Download
1.3.0

Function now natively supports sub-groups, handles NaNs more robustly, and returns sample size(s). A few other minor tweaks and doc changes.

Download
1.2.0

Moved quantile calculation to new function.

Download
1.1.0

Changed/corrected quantile estimation algorithm. Details in help text.

Download
1.0.0

Download
To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.