> On Apr 8, 2015, at 6:46 PM, Bruno Nicenboim <
bruno.n...@gmail.com> wrote:
>
> Thanks for all the comments! I'm attaching all the code now.
>
> So I managed to compare the log normal model vs shifted log normal (v2). The shifted log normal model recovers the parameters that I simulated (betas= (5, .12, .05,.08), shift =180, sdev -.7, etc) quite well, and its WAIC is lower than the one of the regular (non shifted) log normal model.
> I still haven't tried to to do the comparison with the cross validation approach, I'll try it soon
>
> My problems (that maybe I should post them in a different thread):
> * The model which assumes reciprocal normal distribution is not working at all after I implemented the increment_log_prob(log(1000) + -2 * log(y));
The log Jacobian should be
log abs(d/d.rt -1000 * rt^(-1))
= log(abs(-1000 * (-1 * rt^(-2)))
= log(1000 * rt^(-2))
= log(1000) -2 * log(rt)
So the Jacobian looks right.
Where does the y come in?
If rt (or if that's what's named y) is just data, the Jacobian
will be constant and won't matter for sampling.
> . It's very likely I'm overlooking something completely idiotic (sorry if that's the case), or that I'm doing something quite idiotic. (This is the model that I originally had with -1000/rt transformation of the data (I called that stan file recip, and the models ir - sorry for the confusion) )
If rt is negative, you have a problem in that log(rt) will fail.
> * Most of the Rhats are over 1.00, some of them even 1.07 (up to 1.07 in the shifted log normal (v2) and up to 1.03 in the regular log normal model). The traceplots of shifted log normal (v2) don't look that bad, but I think they aren't mixing completely. Any recommendations? I'm using now priors that I think make sense given the data, but it didn't help
So you either need to run longer or reparameterize to get better
mixing.
- Bob