Here is a list of the array methods:
sort() and argsort()
These methods default to sorting the flattened array (returning an ndarray). If given an axis keyword, then it is possible to preserve the axes meta-data only if there are no ticks on the sorted Axis. Otherwise, an ndarray is returned.
These methods do not fit into a simple pattern, and are explicitly overloaded in the DataArray class definition.
These methods are wrapped in a generic runner that pays attention to which axis is being trimmed out (if only one), and then sets the remaining axes on the resulting array. It also allows for the translation of Axis-name to Axis-index.
These methods are currently wrapped as a generic reduction.
These methods return an index, or an array of indices into the array in question. That significantly changes the model of the array in question. Should the return type here NOT be DataArray?
These methods are wrapped in a generic accumulator.
These methods have the property of taking an “axis” keyword argument, and yet not eliminating that axis. They also default to working on the flattened array if the axis parameter is left unspecified.
Possibly N/A methods?
Reshaping is prickly.. I’ve already implemented certain slicing mechanisms that can insert unlabeled axes with length-1. This seems legitimate. Also squeezing out length-1 seems legitimate (even if the Axis is labeled?).
The reshaping currently only trims or pads the array shape with 1s, or flattens the array entirely (returning an ndarray).