Skip to content

Commit cfbb2b3

Browse files
Add clear docstrings
1 parent 66f3b2d commit cfbb2b3

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

src/vextrema.jl

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
############################################################################################
77
# interface
88
"""
9-
vvextrema([f=identity], A::AbstractArray; [dims=:], [init=(mn,mx)])
9+
vextrema([f=identity], A::AbstractArray; [dims=:], [init=(mn,mx)])
1010
1111
Compute the minimum and maximum values by calling `f` on each element of of `A`
12-
over the given `dims`, with the `mn` and `mn` initialized by the respective arguments
12+
over the given `dims`, with the `mn` and `mx` initialized by the respective arguments
1313
of the 2-tuple `init`, which can be any combination of values (`<:Number`) or functions
1414
which accept a single type argument.
1515
@@ -42,6 +42,13 @@ vextrema(A; dims=:, init=(typemax, typemin)) = vextrema(identity, init[1], init[
4242

4343
# handle convenience cases
4444
vextrema(f, initmin, initmax, A, dims::Int) = vextrema(f, initmin, initmax, A, (dims,))
45+
46+
"""
47+
vextrema([f=identity], A::AbstractArray, dims=:)
48+
49+
Compute the minimum and maximum values by calling `f` on each element of of `A`
50+
over the given `dims`.
51+
"""
4552
vextrema(f, A, dims) = vextrema(f, typemax, typemin, A, dims)
4653
vextrema(A::AbstractArray, dims) = vextrema(identity, A, dims)
4754

0 commit comments

Comments
 (0)