Why does an electric shock to the hand cause the fist to clench the wire firmly?
Actually an electric shock across the hand does not do this. The kind of shock you are talking about is one where the current travels up the arm. The current causes all the muscles in the arm to contract, and in your forearm you have some large muscles that control gripping of your fingers. You have more power in those muscles than in the small muscles that cause the fingers to open, so the result is that the hand grips, and if it happens to grip a live wire, then you cannot let go.