JuliaStats / Distributions.jl

A Julia package for probability distributions and associated functions.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Changing the type from `Float` to `Int` breaks `mean` of `MixtureModel`

Vilin97 opened this issue · comments

julia> using Distributions, LinearAlgebra

julia> MixtureModel(MvNormal[MvNormal([-1.,0.], I(2))], [1]) |> mean
2-element Vector{Float64}:
 -1.0
  0.0

julia> MixtureModel(MvNormal[MvNormal([-1,0], I(2))], [1]) |> mean
ERROR: MethodError: no method matching axpy!(::Int64, ::Vector{Int64}, ::Vector{Float64})