None of this is bad advice and Tightends reccomendation that you use clean outs only will make sure you never get involved when you are behind, but you will be passing on some situations where you are ahead (on pot odds).
This is where assigning a range of hands to your opponent comes in. Most mere mortals can't say definitively what your opponent is holding (Peter Costa can according to Tikay's tales - theres a game to avoid), but you can have a good guess at working out what range of hands they may have.
Experience will tell you what kind of hands they are playing, are they tight or loose, aggressive or passive. You can use this information to inform your outs calculation. You should have a go at working out what % of the time this opponent may be bluffing or semi-bluffing and whether they would make this move with top set or an overpair. If you reason then that 2 out of 3 times they will have an over pair (less than KK) or worse then your 6 outs for Aces or Kings would be 'worth' 4 outs. Thus you would have 13 outs and the rule of 4 gives you 52% and much better pot odds.
In actual fact if you could put your opponent on

then you would be a 55/45 favourite with

on a flop of

.
The problem is putting your opponent on a range of hands and assigning them a probability. This is a best guess scenario and relies on 'extra' information such as their style and any tells you can pick up. It seems like hard work but it will make a difference in the long run.
To illustrate this in the £5 rebuy at Blackpool on Sunday I saw a guy make a fantastic laydown with QQ preflop because he was absolutely certain the lady who re-raised him had AA or KK. He had 2.5-1 pot odds to call all in but passed. She had KK and he got plenty of stick for laying QQ down when the turn brought a Q. I thought he made a great play especially considering the company he was in.
Lastly, there are plenty of books out there which do a better job than I of explaining things, Harrington volume 1 is a good start.