Hi everyone,

I am trying to fit a spike and slab regularization prior for logistic regression model. For that I am going to use following mixture of priors.

My code is as follows:

```
data {
int<lower=1> N;
int<lower=1> K1;
int<lower=0,upper=1> y1[N];
matrix[N,K1] x1;
}
parameters {
real alpha;
real<lower=0,upper=1> theta;
vector<lower=0>[K1] tauj_sqr;
int <lower=0,upper=1> gammaj[K1] ;
vector[K1] spike_j;
vector[K1] slab_j;
}
transformed parameters {
vector[K1] beta_j = gammaj .* slab_j + (1-gammaj) .* spike_j;
}
model {
slab_j ~ normal(0, sqrt(tauj_sqr)) ;
spike_j ~ normal(0, sqrt(0.001)) ;
gammaj ~ bernoulli(theta);
theta ~ beta(0.5,0.5);
tauj_sqr ~ inv_gamma(0.5,0.5);
alpha ~ normal(0, 5);
y1 ~ bernoulli_logit_glm(x1, alpha, beta_j);
}
```

However, I am getting an error regarding to the following line of code :

`int <lower=0,upper=1> gammaj[K1] ;`

Can anyone guide me how to fix this ?

Also will there be any efficient parameterization that can be used for spike and slab priors ?

Thank you