@AngleWyrm There may have been an ad hominem but the concerns are real. And if we're being honest there are times where I feel like you're only contributing negatively to the discussion (because what you're contributing is sometimes objectively wrong and misleading to the OP). We appreciate...
As it should. But simulating from the likelihood isn't really defensible from a frequentist perspective. I'm being pedantic but if that's what you want to do it really makes the most sense to at least acknowledge you're taking a bayesian approach.
It is. But like you said it must be iid and this ends up with a symmetric distribution which i don't think quite fits the needs here. Plus is a convolution really simpler than an if/else?
Honestly that's probably a better suggestion for this. Going the full Beta route might be nicer if it's possible to code easily but the triangle distribution would probably work quite well here. I guess it all comes down to the specifics of what attributes are necessary from the distribution.
@AngleWyrm were you perhaps trying to illustrate inverse transform sampling but got the details wrong?
https://en.m.wikipedia.org/wiki/Inverse_transform_sampling
@Bman28 let me know if my suggestions on how to do it in Lua help or not. I'm not sure if any of that requires any external packages or whatever because I don't use Lua but wanted to help.
@AngleWyrm ....
Are you trying to help? There might be a crumb of usefulness in that post but almost every contribution to this thread that you've made is a net detriment in my mind. You post some things that are kind of related but aren't really useful to what they're trying to do. Maybe...
Actually I might not have read closely enough. I think you can directly sample - you just need to provide a prng instead of a qrng. If that's the case it should be as easy as creating the distribution object and calling it's sample method with a prng of your choosing.