create_2d_mesh()#

function create_2d_mesh(x, y, scale=64, *, density=True, weights=None, zero_min=True, padding=0)#

Create a square 2d mesh of the provided data space.

Parameters:
  • x (ndarray) – the x coordinates

  • y (ndarray) – the y coordinates

  • scale (int) – the size of the 2d mesh bins to create.

  • density (bool) – whether to normalize the histogram

  • weights (ndarray | None) – the weights to use for the histogram

  • zero_min (bool) – whether to set the minimum values to zero

  • padding (int) – the amount of padding to add to the limits

Return type:

tuple[ndarray, ndarray, ndarray]