I have a probability distribution, e.g. Y = Normal()
and would like to scale the distribution (updating its pdf, cdf, etc.) by a nonrandom function, say f(x) = cdf(Normal(1,2),x)
.
Is there a way to do this and have the the result be a Distributions.jl distribution? I could define g(x)=pdf.(Y,x)*f(x)
, use rejection sampling to get samples from g(x)
, then fit a distribution to those data, but it seems a bit convoluted and am wondering if there is a better way. I realize there could be issues if the support of the resulting distribution changes, but in the case of a Normal()
scaled by the cdf of a Gaussian, this isn’t the case.
Thanks!