Catastrophic shifts in ecosystems