Buy Sell Rules

I have been making use of the documentation but are there any examples of various buy/sell rules. I am looking for buy on %down over a time period below average price and sell at %return after # of weeks?

Also if I use a list and remove a stock does it remove the position based on sell rules or remove it on the next automatic rebalance?

Thanks,

I think these are the rules you are looking for. Let me know if I misunderstood your question.
BUY
SMAPct(30) < - 20 // Buy if 20% below 30 bar MA

SELL
NoDays>=28 and GainPct > 10 //sell if it has been held at least 4 weeks and gain>10%

Removing a stock from the list would not cause it to be sold in the live strategy if the strategy only has the buy rule like InList("your list"). You would need to add a sell rule like InList("your list")=False if you want it to be sold. But if you have the Inlist() in your universe definition then it would sell the stock if you had the "Force Positions into Universe" setting set to No on the Universe & Ranking page.