Configurations in abelian categories: IV. Invariants and changing stability conditions