If you where using a Regular Pokèball at full health, you probably won't catch it, since it has a catch rate of 15.7 % at that time. If it used a Pokemon and got it down to 1 HP, and used one, you would probably catch it. If it was using Explosion, well, that's just pure bad luck. To catch it, use like a Ultra Ball or something, or just catch a ton of Pokèmon and come back. The more Pokemon you catch, the better you will be able to get a critical capture. If Quick Balls where invented, it would recommend, but this is 3rd Gen, anyways. It's just pure bad luck for a Graveler to Explode. :T
Source: Graveler's Pokedex on Serebii and my knowledge of trying to catch stuff.