If you lose a pot or a stack and can feel yourself being overcome by that visceral anger thing, then stop playing IMMEDIATELY - it's the hand after this one which will put you in the most danger. I find it tends to only take 5 or 10 mins to calm down and re-focus, by which time I probably haven't even lost my seat (should I be at a table on which I want to continue).

I also tend to get a bit scared when I have a big stack, but only when other factors such as tiredness or boredom start coming into effect. These tend to make me tighten up and play sub-optial poker, and are usually in themselves a good enough reason to stop.