I would like to open with the fact that I do not condone breaking the law. While some of them are there just to make income for the state, particularly if you live in a large city, some of them are there for your own good. If you do anything truly reckless, or if you drive intoxicated or impaired then you deserve what you get and I have no sympathy for you. For minor offenses then I understand you're probably a victim of circumstances so read on.
General avoidence tips:
Anything that makes your car noticeable makes it more likely to be pulled over. Bright colors, modifications, expensive or rare models, being excessively dirty inside or outside. Be aware of these things.
Anything that makes you more noticeable works the same. If you dress in a way that looks unprofessional or slovenly youa re more likely to get a ticket then. It's not fair but that's the way it is.
Cops are more active in the early evening, on holidays and on weekends. These are the times when they are more likely to see someone driving recklessly or speeding and so you are more likely to be pulled over then.
This shouldn't have to be said but obviously having anti police messages on your car (such as 'bad cop, no donut') will get you pulled over more often. It's just stupid to have such things, leave them off.
Stupid things not to do:
Do NOT admit or allude to any kind of guilt when you are pulled over. Ignorance is your friend. do not begin by asking if you were doing something, particularly asking if you were doing something specific. Don't ask the officer what the problem is, it just annoys them. Just shut up and wait. Don't be too brief with answers so as to seem as if you are hiding anything either.
Do NOT accuse the officer of any alterior motives. Yes I know it's possible that they are racist, sexist, or homo phobic but you will not be able to prove it and it only angers them either way. They will never once admit they were profiling and be on thier merry way just because you accused them of it. Don't do anything in anger, don't get angry at all, the best way to deal with anyone is to be reasonable no matter how unreasonable they are. Don't make the officer defensive. Don't mention your lawyer, don't ask for thier information, don't threaten them. Don't ask to see the radar gun, or for any proof of what you did, they can fake it all believe me.
do NOT say you need to go to the hospital unless you really have to. The officer will escort your ass down there and be pissed when you don't need it. You can expect an extra charge then.
do NOT pretend you are a cop yourself, they all know each other and you'll just look stupid. Don't pretend to know anyone either. Name dropping is just pathetic and it won't save you. If you must name drop then don't be obvious, such as by saying: 'do you know *insert name*'. Say something more like 'I was on my way to see my father, he's a new york city judge'. Believe me either way it's hopeless but at least try not to look stupid.
do NOT flirt or insinuate you can bribe them with sex or even money. It's unlikely to work and the risk is great. Don't try it, just act profesional.
Things you might try:
Cry. Keep in mind that this works best if you're a woman under 40 or a man under 20, at least noticeably. Either way it can't hurt you much to try it. Be comitted to it though and only do it if you know you can be convincing. Have a reason, like that you can't afford this, it'll make you lose your job or your scholorship. Begin crying as soon as the officer apporahces and keep it up as obnoxiously as possible. when the officer aks if you are okay always answer no. You may make them uncomfortable enough to let you go. It's possible you'll get a particularly sadistic or emotionless officer, but unlikely. I reccomend this strategy if you can pull it off.
'I have to pee, officer.' If this is your defence then you can't wait for an excused to be asked for, it has to be the first thing out of you. Ask them to follow you to a rest stop, don't ask to just go. If asked if you can hold it say you don't think so. If the officer continues then cross your legs and fidget a lot. look very uncomfortable. Usually if you can sell it then the officer will rather let you go rather then discuss it. Don't lose hope if they follow you to a rest stop, they might accept your excuse. If you begin this strategy then don't relent the entire time, lest you look like a liar.
Be funny. Unsurprisingly, being a traffic cop isn't fun. They get to hear the same crap every day from everyone. If you can tell them something unique or amusing it may make them go easy on you. Just don't do anything stupid like insult them. No matter how many stories you've heard about that working, it doesn't. find a very inoffensive way to be funny or otherwise don't do it. A good tactic here is to tell too much truth. If you werre speeding because you were racing someone, then tell the officer that. If you're obviously not going to be able to pretend you did nothing or didn't know then be entirely honest. Sometimes the honesty is so refreshing it makes them easy on you.
Complete ignorance. Again, if you're going to do this one then committ to it. Do not say anything until you are asked a question or told something and then respond with ignorance. examples: 'How fast was I going?', 'was there a stop sign back there?', 'u turns are illegal here?'. This is low risk and puts you on decent footing to be found at less fault.
Well that's all, best of luck to you. Feel free to post your own tips in the comments.