When trying to meditate, do you get distracted by “bad” thoughts (e.g., greed, hatred, etc)? In the Vitakkasaṇṭhāna Sutta (Majjhima Nikaya 20), the Buddha gives 5 suggestions to get rid of them…
First, try to replace the bad thought with a good thought (loving kindness, etc), “just as a skilled carpenter or his apprentice might knock out, remove, and extract a coarse peg by means of a fine one.”
If that doesn’t work, realize the danger of that bad thought, “Just as a man or a woman, young, youthful, and fond of ornaments, would be horrified, humiliated, and disgusted if the carcass of a snake or a dog or a human being were hung around his or her neck.”
If that doesn’t work, attend away from that thought, “Just as a man with good eyes who did not want to see forms that had come within range of sight would either shut his eyes or look away.”
If that still doesn’t work, try to slow down the stream of mental activity, “Just as a man walking fast might consider: ‘Why am I walking fast? What if I walk slowly?’ and he would walk slowly; then he might consider: ‘Why am I walking slowly? What if I stand?’ and he would stand; then he might consider: ‘Why am I standing? What if I sit?’ and he would sit; then he might consider: ‘Why am I sitting? What if I lie down?’ and he would lie down. By doing so he would substitute for each grosser posture one that was subtler.”
Finally, if nothing works, the drastic measure, suppress the thought, “Just as a strong man might seize a weaker man by the head or shoulders and beat him down, constrain him, and crush him, so too… when, with his teeth clenched and his tongue pressed against the roof of his mouth, a monk beats down, constrains, and crushes mind with mind… his mind becomes steadied internally, quieted, brought to singleness, and concentrated.”
The Buddha can clearly give very, very colorful metaphors!