concreteproperties.post.plotting_context#

plotting_context(ax=None, pause=True, title='', aspect=False, filename='', render=True, axis_index=None, **kwargs)[source]#

Executes code required to set up a matplotlib figure.

Parameters
  • ax (Optional[Axes], default: None) – Axes object on which to plot

  • pause (bool, default: True) – If set to true, the figure pauses the script until the window is closed. If set to false, the script continues immediately after the window is rendered.

  • title (str, default: '') – Plot title

  • aspect (bool, default: False) – If set to True, the axes of the figure are set to an equal aspect ratio

  • filename (str, default: '') – Pass a non-empty string or path to save the image as. If this option is used, the figure is closed after the file is saved.

  • render (bool, default: True) – If set to False, the image is not displayed. This may be useful if the figure or axes will be embedded or further edited before being displayed.

  • axis_index (Union[int, Tuple[int], None], default: None) – If more than 1 axes is created by subplot, then this is the axis to plot on. This may be a tuple if a 2D array of plots is returned. The default value of None will select the top left plot.

  • kwargs – Passed to matplotlib.pyplot.subplots()