Buy stop sell stop for optimize

Hi , Friends

I am trying optimize some afl. Buy sell code

Buy=Cross (SK,SD) ;
Sell=Cross(SD,SK) ;

Short = Sell;
Cover = Buy;

How can I add Buystop and sellstop

Buystop : When cross SD,SK and SK > 50

Sellstop : When cross SK,SD and SK<50

Broker Special Offers

Intraday Higher Leverage

Save up to 90% in brokerage and get higher leverage for intraday trades.

Are you a day trader?