See below a Stan program, given the data I can run Bayesian inference to estimate the parameters, but I cannot sample new data using estimated parameters – i.e., the model in the below Stan program is NOT generative.
I am wondering since the model is not generative, can we trust the inference on parameters?
Any help or comments arre appreciated?
vishy
data {
int<lower=1> T; // number of periods
int<lower=1> N; // number of items
matrix[T, N] X; // cash flow data
vector[T] f; // quarterly returns
}
parameters{
real<lower=-1, upper=1> alpha;
real<lower=0, upper=3> beta;
real<lower=0, upper=1> sigma;
real<lower=0> tau;
vector<lower=-1, upper=10>[T] delta; // discount rates
}
transformed parameters {
vector<lower=-1, upper=10>[N] y; // discount rates
vector<lower=-1, upper=10>[T] r; // discount rates
r[1] = 1 / (1 + delta[1]);
for (t in 2:T) {
r[t] = 1 - delta[t - 1] / delta[t];
}
y = dot_product(X', delta)
}
model {
// inference
r ~ normal(alpha + beta*f, sigma)
y ~ normal(0, tau);
// non informative priors
alpha ~ cauchy(0, 1)
beta ~ cauchy(0, 1)
sigma ~ cauchy(0, 1)
tau ~ cauchy(0, 1)
alpha ~ cauchy(0, 1)
delta ~ cauchy(0, 1)
}