osyris.scatter

Contents

osyris.scatter#

osyris.scatter(x, y, color=None, size=None, logx=False, logy=False, loglog=False, norm=None, filename=None, title=None, xmin=None, xmax=None, ymin=None, ymax=None, vmin=None, vmax=None, aspect='auto', ax=None, **kwargs)#

Make a 2D scatter plot with two variables as input.

Parameters:
  • x (Array) – Array to use for scatter point positions along the horizontal dimension.

  • y (Array) – Array to use for scatter point positions along the vertical dimension.

  • color (str | Array | None) – The color of the scatter points. Can be a string or an Array. If an Array is supplied, a colormap is used. Default is None.

  • size (float | Array | None) – Size of the scatter points. If a float is provided, all points will have the same size. If an Array is provided, the size of each point will be determined by the values of the Array. Default is None.

  • logx (bool) – If True, use logarithmic scaling on the horizontal axis. Default is False.

  • logy (bool) – If True, use logarithmic scaling on the vertical axis. Default is False.

  • loglog (bool) – If True, use logarithmic scaling on the horizontal and vertical axes. Default is False.

  • norm (str | None) – The colormap normalization. Possible values are 'linear' and 'log'. Default is None (= 'linear').

  • filename (str | None) – If specified, the returned figure is also saved to file. Default is None.

  • title (str | None) – The title of the figure. Default is None.

  • xmin (float | None) – Minimum value for the horizontal axis. Default is None.

  • xmax (float | None) – Maximum value for the horizontal axis. Default is None.

  • ymin (float | None) – Minimum value for the vertical axis. Default is None.

  • ymax (float | None) – Maximum value for the vertical axis. Default is None.

  • vmin (float | None) – Minimum value for colorbar range. Default is None.

  • vmax (float | None) – Maximum value for colorbar range. Default is None.

  • aspect (str) – The aspect ratio of the plot. Default is 'auto'.

  • ax (object | None) – A matplotlib axes inside which the figure will be plotted. Default is None, in which case some new axes a created.

Return type:

Plot