StatisticalRethinkingJulia / TuringModels.jl

Implementations of the models from the Statistical Rethinking book with Turing.jl
https://statisticalrethinkingjulia.github.io/TuringModels.jl/
MIT License
164 stars 17 forks source link

Update to `quap` to Turings MAP #26

Closed karajan9 closed 4 years ago

karajan9 commented 4 years ago

As mentioned before, with Turings new capabilities things get much easier. We don't have to find a starting point and adding return statements to the model is not necessary.

I'm not sure if making a difference between the 1D case and the rest makes sense, it's just a little more convenient because it allows rand(distr, 10) to return a Vector then. But then again, 1D isn't really that special.

I was thinking about adding a QuApResult type so we can have convenient rand(result), precis(result) (or what else have you) functions.

karajan9 commented 4 years ago

I just noticed that adding start values for the optimization errors: https://github.com/TuringLang/Turing.jl/issues/1298

goedman commented 4 years ago

Nice catch! No doubt will be fixed soon! Shall we merge or hold off until this is fixed?

karajan9 commented 4 years ago

I don't think I have an opinion on this. It's not really used anywhere right now (except by me internally) so I don't think it makes much of a difference.

goedman commented 4 years ago

Ok, I’ll merge it.