Breaking 'bad habits': a dynamical perspective on habit formation and change