I am trying to carry out a simple linear regression with p predictor variables. If the coefficients follow normal distribution individually then how to concisely define the prior over all these coefficients in most efficient way suppose inside a loop? For example,
beta0 = Normal("beta0", mu=0, sigma=20) # Intercept
beta1 = Normal("beta1",mu=0, sigma=20) # Coefficient1
beta2 = Normal("beta2", mu=0, sigma=20) # Coefficient2
beta3 = Normal("beta3", mu=0, sigma=20) # Coefficient3
For small problems specifying the priors in above way is not a challenge. But for bigger problems its quite challenging.
In this case how to specify the priors over the coefficients in a concise form like the following?
for jj in range(3):
beta[jj] = Normal("beta", mu=0, sigma=20)
Thanks in advance.