I think a flow chart could best explain what to do here. Basically as Big Rat said, you always want to turn hard G's (actually if he is quite a bit faster you can turn soft G's and lure him in as mtnman eluded to) with your nose down (nose up/straight flat=probably dead). If you are low already, it would be best to start flat and then bend low as he gets <1.1k ish.
Basically, If he:
-pulls up and breaks off due to a dangerous downward angle: continue going straight building E, and slowly climbing (if you are low), and if he pursues again, reengage with a downward angle and rinse repeat until he has wasted enough E.
-continues and appears to have impending gun solution: twist your plane 90 degrees right before he fires and pull up or push down (it won't take much) and avoid him (As Soulyss pointed out), build E, rinse repeat as necessary.
-continues and appears to have impending gun solution BUT ALSO appears to have chopped throttle: chop throttle, twist your plane 90 degrees, pull up or push down, and force scissors.
Those 3 conditions are as rigid as they get and do not take into account plane types, pilot, or particular airspeed differences, but understanding those 3 conditions in principle, and then becoming flexible with your approach will allow you to cover your base against a wide variety of attacks.