Hi Michael -
There are a couple of ways of doing this. The simplest might be to simulate the data like so:
data {
int N;
int P; // number of predictors
real<lower = 0> sigma; // your "known" error scale
vector[P] beta; // your "known" coefficients
matrix[N, P] X; // your predictors, including a column of 1s
}
parameters {
vector[N] yhat;
}
model {
yhat ~ normal(X*beta, sigma);
}
If you run that, each draw would be a sample you could use to test your model with. Your question mentioned having LKJ priors (I presume for random effects on betas covariance?). So you want to provide known group-level betas to exhibit correlation consistent with your prior? If so, you could export the lkj_corr_rng() function from Stan to R. Your Stan program would be
// saved as export_lkj.stan
functions {
matrix lkj_rng(int size, real eta) {
return( lkj_corr_rng(size, eta));
}
}
model {}
at the top. You can then extract the lkj rng function using
rstan::expose_stan_functions(export_lkj.stan)
After which the function lkj_rng() will be available for use in your R session.
Hope this helps. FWIW I normally do all my fake data stuff in R.
Jim