using Distributions, Compat, Random
┌ Info: Recompiling stale cache file /Users/takuizum/.julia/compiled/v1.1/Distributions/xILW0.ji for Distributions [31c24e10-a181-5473-b8eb-7969acd0382f] └ @ Base loading.jl:1184
rand(Normal(), 10) # random variables
10-element Array{Float64,1}: 1.6361645707228596 -0.22727792694347274 -0.45358881970524206 -0.7145358539538202 0.7859056208616061 0.4669574803574423 -0.12399544433112841 0.43294264792177606 0.0834266734688481 1.4500301443642536
# estimate distribution parameters
Sample = rand(Binomial(), 1000)
fit(Normal, Sample)
Normal{Float64}(μ=0.494, σ=0.4999639987039028)
[1,2,3]
3-element Array{Int64,1}: 1 2 3