# Sum or convolution of discrete uniform random variable

**URL:** <https://discourse.julialang.org/t/sum-or-convolution-of-discrete-uniform-random-variable/15426>\
**Category:** Statistics\
**Tags:** package\
**Created:** [September 24, 2018, 1:43pm UTC](https://discourse.julialang.org/t/sum-or-convolution-of-discrete-uniform-random-variable/15426 "2018-09-24T13:43:19Z")\
**Posts on this page:** 1\
**Showing post:** 11

<div class="post-metadata">

**Author:** ![acwatt](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/acwatt/32/35645_2.png) [@acwatt](https://discourse.julialang.org/u/acwatt)\
**Post date:** [March 3, 2023, 2:22pm UTC](https://discourse.julialang.org/t/sum-or-convolution-of-discrete-uniform-random-variable/15426/11 "2023-03-03T14:22:14Z")

</div>

In case anyone stumbles across this thread, a related convolutions thread (and some updated packages, code snippets, and solutions) is here:

> [@Distribution of sum of random variables](https://discourse.julialang.org/t/distribution-of-sum-of-random-variables/69023/5):
>
> As @mschauer said, it would be helpful to get more information. But in lieu of that, I’ll assume we’re talking about continuous univariate random variables being scaled by real scalars and added. First, Distributions.jl can handle the scaling with no problems, e.g. julia\> using Distributions julia\> Normal() \* 5 LocationScale{Float64, Continuous, Normal{Float64}}( μ: 0.0 σ: 5.0 ρ: Normal{Float64}(μ=0.0, σ=1.0) ) Addition of random variables is more complicated. The distribution of the sum of …

Note that Distributions.jl and it’s current `Distributions.convolve` function only support a subset of distributions (namely, not uniform random variables, discrete or continuous).

---

_[View the full topic](https://discourse.julialang.org/t/sum-or-convolution-of-discrete-uniform-random-variable/15426)._
