My 83 had very similar problems when I first bought it.
Check the ignition module, the black square on the side of the distributor. Pull the dist cap off and make sure the red and green wires are secure in the top of the ignition module, and make DOUBLE sure that the red and green spade connectors are not poking sharp bits of themselves into the insulation of each other. Mine was doing that, which now and then caused the pickoff coil to short to itself. Check and reseat the two wire connection leading to the main ignition coil.
Check the two heavy black wires from the battery positive post to the fusible link box (right next to the battery). Make sure they are making excellent contact and are not corroded in any way. Make sure all the fusible links in the box are also making excellent contact and are not corroded, nor overheated or burnt.
Inspect the ignition switch on the back of the ignition key cylinder, make sure that the wires have good contact, and that the connector is fully seated.
Inspect the connectors to the air flow meter next to the radiator, and the throttle valve switch on the side of the throttle body.
My car had problems in all those places. It runs pretty well now! Good Luck