Closed xuxuxuzz closed 6 years ago
Indenting really helps with code. I edited to escape with three backticks (```
) on their own line.
I'm not sure what you mean by a shrinkage uniform prior. Shrinkage is a notion from point estimation which usually pushes estimates toward zero---you're just restricting to a range. That shouldn't be a problem, though we don't recommend interval-bounded priors because they are poorly behaved statistically and computationally if values very close to the boundaries are consistent with the data.
What's happening is that you're providing an undefined variable to the normal distribution. Figure out what line 23 of your code is (helps to have Stan programs in their own files). Then make sure all the variables are defined.
Please follow-up on our forum if you need more help:
This isn't a bug report on Stan, so I'm going to close the issue.
Recently, I have been studying the Stan example of Magnesium meta-analysis(). It works well as a whole. However, when I tried to use shrinkage uniform prior only, it didn't work. Here is the code that I have rewritten according to the Magnesium meta-analysis example.
This is the warning I have got!
I try to change the position of
vector[N_studies] tmpm;
to the first line of the model block. It still didn't work This is the warning.Can anyone tell me what the problem this is and how to write it correctly? I will highly appreciate your help.
[edited to escape code]