I am trying to run Generalized Fiducial Inference and have the following code. When I run this, I get the error that the dims declared are 19, but the dims found are (19,19). I have tried converting to an array, but haven’t had luck. Any ideas on how to fix?

library(rstan)

x<-list(1,2,3,2,7,2,4,8,24,78,6,24,21,2,3,7,3,58,246)

ds <- list(N = length(x), y = x)

gfi_model = "

data {

int<lower=0> N; // number of observations

int<lower=0> y[N]; // outcome variable

}

parameters {

real mu;

}

model {

mu ~ normal(0,10); // our prior for mu

}

generated quantities {

real effect;

effect = mu+mu^(3/2)*(N-mu/(mu));

}

"

fit <- stan(model_code = gfi_model, data = ds, iter = 1000, chains = 4)