Assessment and control for confounding by indication in observational studies