Hi Stan Experts. I am new to Bayesian and brms. I am trying to run multivariate regression using Bayesian. I am working with 10M records at customer cross week level with sales as dependent variable and other different predictors.
I dont have any informative priors and also I cannot run the entire 10M records on the server, hence I took Q3 of the 10M data and again took a further subset of 10%(say rawdb4). I plan to run bayesian regression model on this rawdb4 using brms library in R, without providing any priors. As output, I would get some Beta and Est. Error for each of the predictors. I plan to use these Beta and Est. Error as Priors for rest of the data. I am facing below challenges:
-
Est. Error from rawdb4 model for all the predictors is zero (hence I am not able to define a distribution for these predictors as priors). What could be the possiible reason?
-
I tried with some random values as priors(for e.g N(x,sd)) and I observed that the smaller the value of standard deviation I pass, more my model results are closer to priors and the opposite if the value is larger. How shall I decide my priors then?
bmod1 <- brm(
Y ~ Samp + C_95 + CR_85 + LE+ SPD90 + CPA + FTO,
data = rawdb4, family = gaussian(),
warmup = 600, iter = 3000, chains = 4,
control = list(adapt_delta = 0.98), cores=16, seed=150)
prior1 <- c(
prior(normal(10, 100), class = Intercept),
prior(normal(0.07, 100), class = b, coef = Samp),
prior(normal(0.2, 100), class = b, coef = C_95),
prior(normal(0.1, 100), class = b, coef = CR_85),
prior(normal(0.06, 100), class = b, coef = LE),
prior(normal(0, 100), class = b, coef = SPD90),
prior(normal(0.47, 100), class = b, coef = CPA),
prior(normal(0.55, 100), class = b, coef = FTO),
prior(cauchy(10, 10), class = sigma)
)
bmod2 <- brm(
Y ~ Samp + C_95 + CR_85 + LE+ SPD90 + CPA + FTO,
data = rawdb3, family = gaussian(), prior = prior1,
warmup = 600, iter = 3000, chains = 4,
control = list(adapt_delta = 0.95), seed=150, thin=3,
cores = parallel::detectCores()
)