M.D.
My daughter did similar things around that age. Anytime anything didn't go exactly her way she would take it out angrily on either herself or others around her. I finally asked her pediatrician because it got so bad that her little forehead stayed black and blue from beating it on the hardwood floors so often. Then she would beat it harder because she was angry that it hurt. I really thought something was wrong for her to be doing that!! And then the biting began. And she would leave marks on herself for days!! It was SO aweful. What her Dr. told me, was that if you react to it (or anyone else in the room with you reacts to it) then you are only encouraging the behavior. He told me to put her on a soft mat where she couldn't beat herself or hurt self in another room without saying anything or acknowledging it AT ALL and let her do it!! We did that, and within days, there were major improvements!! Within a week, the behavior had completely stopped!! Its hard to just let them throw the fit, but it really did work quickly for us. Just thought I'd let ya know what her Dr. said and see if that would help ya!! He said some kids just don't quite know how to deal with their anger yet and so they resort to this and they need to learn that it won't get them attention to hurt themselves!! Good Luck!!
~M.