CartesianIndex version of find/findnz? #20684
Labels
arrays
[a, r, r, a, y, s]
collections
Data structures holding multiple items, e.g. sets
design
Design of APIs or of the language itself
search & find
The find* family of functions
speculative
Whether the change will be implemented is speculative
Seems like it would be useful to have a version of
find
that returns a vector of cartesian indices, in analogy to the newenumerate
.findnz
is basically a pre-CartesianIndex version of this idea that only happens to work for 2d arrays.One possible API, in analogy with the enumerate API, is to have
find
take a singleton-valued first parameter that selects the output format.Thoughts?
The text was updated successfully, but these errors were encountered: