Hi, I’m working on a model which has a small number of variables. To gain some insight (I hope) I am thinking that I’ll evaluate the posterior on a fixed grid of points, let’s say m^n points where each of n variables is divided into m equally spaced values. (The priors for all variables are uniform, so evaluating the posterior is equivalent to just evaluating the likelihood function.)

Is there a way to tell Stan that I want to sample on a fixed grid? Or perhaps a way to say that I want to evaluate the posterior at a specified list of points? Then I would just generate the grid points and put them in a list. (If I can get that working, I would be interested to try low-discrepancy sequences a.k.a. quasi Monte Carlo, although that’s a lower priority.)

I realize that grid sampling doesn’t make sense in more than a few dimensions, but luckily, I am indeed working in just a few dimensions. Thank you in advance for any light you can shed on this question.

best,

Robert Dodier