As for when to sell a stock, this is the hardest decision. Ideally, when the trend changes against me, I see it necessary to sell.
I sell when it appears I am in danger of losing profits and the stock may not be volatile enough to regain lost ground quickly. However, if the stock is powerful, I accept that breakouts may not always hold. I will watch if it holds a somewhat wide price level before selling. With these jumpy stocks, patience, given the right situation, can keep me in for future larger gains while avoiding a small short-term loss. If support levels are lost, I will exit and should have anticipated it by now.
If I own a stock that gaps down huge in price, I sell that same day. While a person could wait or average down, I find it hard to perfectly time the exit later. A stock that is down huge will likely be a huge loss, to a varying degree higher or lower. I prefer to get it over with and find the next winner. I can improve by watching a huge loser intraday, taking a daytrader's perspective, and making the most out of it.
Generally speaking, I prefer to not be super active. I'd rather let a stock run for a long time and make money without having to enter and exit a stock over and over again.
However, after I sell a stock, I immediately place a price alert for when that stock will interest me again. Doing so can help me decide to get back in if conditions are right. And, I would rather not miss a huge winner in the future.
In some cases, round numbers for stock prices are obvious exits for traders. At times, I see 20% gains as targets not to be given up during favorable market conditions. In less certain times, a 10% gain could be impressive. Experience and consideration will make me a better trader and know best when to sell.
Whether selling a stock for a huge gain or loss, I do not dwell on it. I learn from success or failure -- the simple measure of the market.