I have an array defined as the following:
julia> a = [5, 6, 7, 8, 10, 12, 12, 17, 67, 68, 69, 72, 74, 74, 92, 93, 100, 105, 110, 120, 124]
21-element Vector{Int64}:
5
6
7
8
10
12
12
17
67
68
⋮
74
74
92
93
100
105
110
120
124
I am able to calculate the standard deviation but there does not seem to be a mode function built into Julia like there is with the std() function.
While there is no built in function to do this, the mode function does exist in the StatsBase package:
julia> using StatsBase
julia> mode(a)
12
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With