with logistic_model:
mean_field = pm.fit(n=100000, method='advi')
trace = mean_field.sample(2000)
az.plot_trace(trace)
More specifically, I am fitting a Bayesian logistic regression with a large data set (1.1 million rows). I found that using n=100000 would be extremely slow, but I’m not sure the appropriate value of n. Is there any method to find a good value of n?