histogram2d(x, y, bins=10, range=None, normed=None, weights=None, density=None)
An array containing the x
-coordinates of the points to be histogrammed.
An array containing the y
-coordinates of the points to be histogrammed.
The bin specification. See the :None:None:`bins`
argument description for histogramdd
for a complete description of all possible bin configurations (this function is a 2D specific version of histogramdd).
The leftmost and rightmost edges of the bins along each dimension when integers are passed to :None:None:`bins`
; of the form: ((xmin, xmax), (ymin, ymax)).
An alias for the density argument that behaves identically. To avoid confusion with the broken argument in the histogram
function, :None:None:`density`
should be preferred.
An array of values weighing each sample in the input data. The chunks of the weights must be identical to the chunking along the 0th (row) axis of the data sample.
If False (the default) return the number of samples in each bin. If True, the returned array represents the probability density function at each bin.
The values of the histogram.
The edges along the x
-dimension.
The edges along the y
-dimension.
Blocked variant of numpy.histogram2d
.
>>> import dask.array as daThis example is valid syntax, but we were not able to check execution
... x = da.array([2, 4, 2, 4, 2, 4])
... y = da.array([2, 2, 4, 4, 2, 4])
... bins = 2
... range = ((0, 6), (0, 6))
... h, xedges, yedges = da.histogram2d(x, y, bins=bins, range=range)
... h dask.array<sum-aggregate, shape=(2, 2), dtype=float64, chunksize=(2, 2), chunktype=numpy.ndarray>
>>> xedges dask.array<array, shape=(3,), dtype=float64, chunksize=(3,), chunktype=numpy.ndarray>This example is valid syntax, but we were not able to check execution
>>> h.compute() array([[2., 1.], [1., 2.]])See :
The following pages refer to to this document either explicitly or contain code examples using this.
dask.array.routines.histogram2d
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them