Skip to content

v4.0.2

Latest

Choose a tag to compare

@github-actions github-actions released this 18 Nov 15:15

4.0.2 : New toolbox thumbnail for the Mathworks file exchange

Full Changelog: v4.0.1...v4.0.2

4.0.1 : Update of the website and readme

  • Shorter readme.md with gallery view
  • Full rework of the website

Full Changelog: v4.0.0...v4.0.1

4.0.0 Summary

This release moves gramm's figure layout to MATLAB's tiledlayout and adds several long-requested features on top of it.

Layout

  • Facets, legends and titles are placed with tiledlayout instead of gramm's custom position computations. Resizing is faster and more reliable, figures with multiple gramm plots keep axes aligned.
  • set_parent(parent,'tile',…,'span',…) can draw a gramm plot in a tile of a tiledlayout, so gramm plots of different sizes and regular axes can be combined.
  • New spacing and padding options in set_layout_options().
  • Long titles (figure, facet, row/column) wrap to the available width, toggled with set_text_options('wrap',…).
  • Figure theme (light/dark) handling is more robust and follows ThemeChangedFcn.

New features

  • Native datetime and duration data for x, y and grouping variables, with time-based bins ('bin_width', e.g. hours(2) or 'month').
  • Native polar axes with set_polar(), including radar charts (requires R2025a).
  • Log axes with set_scale().
  • 'fill_alpha' controls the transparency of shaded areas in every geom and stat that draws them.
  • Line style legends are longer, so that the line pattern is visible.

Consistency and robustness

  • All methods parse their options and validate them.
  • Error bars are native MATLAB errorbar objects throughout.
  • Line width option names unified ('line_width'; the old names are still accepted).

Documentation and CI

  • New layout for the cheat sheet page: sidebar navigation, filter, overview of the steps of a gramm figure, and a dense printable version.
  • The cheat sheet is generated from the method help headers and inputParser options (buildtool cheatsheet), and stays up-to-date. All method help headers were rewritten in a common format.
  • Tutorials and examples are exported by buildtool and published on the website by the release workflow. Generated HTML is no longer tracked.

Breaking changes

  • Requires MATLAB R2022b or later (R2025a for polar plots).
  • set_layout_options() options of the former manual layout ('position', 'legend_width', 'title_centering', 'redraw_gap', 'margin_height', 'margin_width', 'gap') are removed and give a gramm:removedOption error. Custom layouts use set_parent() with a tiledlayout.
  • Numeric color data is no longer switched to continuous colors above 15 values: use set_continuous_color() for scatter plots colored by a continuous variable.
  • Error bars ('errorbar', 'black_errorbar' geoms) are errorbar objects instead of a single NaN-separated line: their XData/YData are now the centers, and their cap size is CapSize, set with set_line_options('cap_size',…).
  • draw() no longer takes an argument: replace g.draw(false) with g.set_layout_options('redraw',false) before draw().
  • set_datetick() is legacy (datenum x only): datetime x data is displayed natively.

Issues addressed

Fixes #93 (errorbar caps), fixes #95 (square y matrix), fixes #101 (many numeric colors), fixes #111 (area transparency), fixes #113 (drawing in App Designer).

Full Changelog: v3.1.2...v4.0.0