Bad electrical is always a possibility, weather it be the ignition switch or spark distribution or even the power to your injectors. Switching the rotor and cap are a good idea cause even if it doesn't work, its cheap and easy and something that needs to be done every once in a while. Just make sure not to throw off the timing when you do it.
__________________
-Joe