I don't think Mike Dean made the decision, rather someone has said something over the comms. If you watch his reaction immediately after the challenge he turns away and isn't even going to give a foul, yet then turns back and gives a massive blast on the whistle. So I'm sure someone has shouted red card over the comms. I can see why as well as the West Ham player has had a bad touch and then lunged in to try and win it back, and that always has alarm bells ringing with referees.
Not a red for me though, and here was a clear example of why referees need to look at player reaction as a valuable tool. When a shocker of a challenge comes in the players always run to either the offender or the referee, and that didn't happen at all here. So in pulling out the red he has managed to surprise absolutely everyone.
Be interesting to see if they appeal and if so what happens. Technically he has left the ground with both feet, hasn't won the player and caught the opponent, so I suspect they may refuse any appeal.