added switches to control lengthy data processing