[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TS6>2000i conversion



PureBytes Links

Trading Reference Links

Great, thanks, Mike.

Cheers,
Ian

> At 05:28 AM 11/24/2002, you wrote:
> >I wonder if some TS6 user would be kind enough to convert this into 
> code >for the rest of us. Some expressions don't seem quite right but 
> it could >be - probably is! - me.
> >
> >It came from www.tradingsystemdesign.com
> >
> >Thanks.
> >
> >Ian
> >
> >{System: Phil Lane's System
> >Category: Short Term Trend Following
> >Duration:  Overnight
> >Compression: Daily
> >Dates: 7/96-9/02
> >}
> >
> >Inputs: ATRLen(10),Lvl(10),GiveUp(2.25);
> >Vars: Atr(0),Eb(0),LStop(0),Mp(0);
> >
> > 
> >Atr=Average(TrueRange,ATRLen);
> >
> >
> >Mp=MarketPosition;
> >
> >If Mp<>1 and c[1]O>L[1] and Atr>Lvl then begin
> >buy this bar on close;
> >Eb=currentbar;
> >LStop=0;
> >end;
> >
> > 
> >
> >If MP=1 and currentbar<>eb then begin
> >LStop=Maxlist(LStop,MaxTradeHigh-GiveUp);
> >Sell next bar at Lstop stop;
> >end;
> >
> >
> >Mp=MarketPosition;
> >
> >If Mp<>-1 and c[1]>o[1] and c[2]>o[2] and c[3]>o[3] and 
> L>Lowest(L[1],3) >and
> >OLvl then begin
> >Sell short this bar on close;
> >Eb=currentbar;
> >LStop=0;
> >end;
> >
> >
> >If MP=-1 and currentbar<>eb then begin
> >LStop=Maxlist(LStop,MaxTradeHigh-GiveUp);
> >Buy to cover next bar at Lstop stop;
> >end; 
> 
> Here's what's different:
> 
> TS2000i         TS6
> Buy                     Buy
> Sell                    SellShort
> ExitLong                Sell
> ExitShort               BuyToCover
> 
> Change the phrases in the TS6 column to the 2000i column, and it'll 
> work.
> 
> HTH
> 
> Mike Gossland
> 
>