Skip to content

Commit

Permalink
use Int for range in discrete distributions
Browse files Browse the repository at this point in the history
  • Loading branch information
mkborregaard committed Sep 7, 2020
1 parent 244355c commit 7992613
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/distributions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function default_range(m::Distributions.MixtureModel, alpha = 0.0001)
end

yz_args(dist) = default_range(dist)
yz_args(dist::Distribution{N, T}) where N where T<:Discrete = (UnitRange(default_range(dist)...),)
yz_args(dist::Distribution{N, T}) where N where T<:Discrete = (UnitRange(Int.(default_range(dist))...),)

# this "user recipe" adds a default x vector based on the distribution's μ and σ
@recipe function f(dist::Distribution)
Expand Down

0 comments on commit 7992613

Please sign in to comment.