julia> findmin(sparsevec([1], [NaN], 2))
(0.0, 2)
julia> findmin([NaN, 0.0])
(NaN, 1)
findmin(itr) -> (x, index)
Return the minimal element of the collection itr and its index or key. If there are multiple minimal elements, then the first one will be returned. NaN is treated as less than all other values except missing.
Indices are of the same type as those returned by keys(itr) and pairs(itr).
See also: findmax, argmin, minimum.
Examples
≡≡≡≡≡≡≡≡
julia> findmin([8, 0.1, -9, pi])
(-9.0, 3)
julia> findmin([1, 7, 7, 6])
(1, 1)
julia> findmin([1, 7, 7, NaN])
(NaN, 4)
x-ref https://discourse.julialang.org/t/julia-stability-vs-rust-for-scientific-computing/137094/11?u=odow
Per the docstring: