dask 2021.10.0

ParametersReturnsBackRef
append(arr, values, axis=None)

This docstring was copied from numpy.append.

Some inconsistencies with the Dask version may exist.

Parameters

arr : array_like

Values are appended to a copy of this array.

values : array_like

These values are appended to a copy of :None:None:`arr`. It must be of the correct shape (the same shape as :None:None:`arr`, excluding :None:None:`axis`). If :None:None:`axis` is not specified, values can be any shape and will be flattened before use.

axis : int, optional

The axis along which values are appended. If :None:None:`axis` is not given, both :None:None:`arr` and values are flattened before use.

Returns

append : ndarray

A copy of :None:None:`arr` with values appended to :None:None:`axis`. Note that append does not occur in-place: a new array is allocated and filled. If :None:None:`axis` is None, :None:None:`out` is a flattened array.

Append values to the end of an array.

See Also

delete

Delete elements from an array.

insert

Insert elements into an array.

Examples

This example is valid syntax, but we were not able to check execution
>>> np.append([1, 2, 3], [[4, 5, 6], [7, 8, 9]])  # doctest: +SKIP
array([1, 2, 3, ..., 7, 8, 9])

When :None:None:`axis` is specified, values must have the correct shape.

This example is valid syntax, but we were not able to check execution
>>> np.append([[1, 2, 3], [4, 5, 6]], [[7, 8, 9]], axis=0)  # doctest: +SKIP
array([[1, 2, 3],
       [4, 5, 6],
       [7, 8, 9]])
This example is valid syntax, but we were not able to check execution
>>> np.append([[1, 2, 3], [4, 5, 6]], [7, 8, 9], axis=0)  # doctest: +SKIP
Traceback (most recent call last):
    ...
ValueError: all the input arrays must have same number of dimensions, but
the array at index 0 has 2 dimension(s) and the array at index 1 has 1
dimension(s)
See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

dask.array.routines.delete dask.array.routines.insert dask.array.routines.append

Local connectivity graph

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


File: /dask/array/routines.py#2357
type: <class 'function'>
Commit: