Dynamical instability in the collapse of anisotropic matter