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

RE: Help with EL for relative strength of stock vs sector



PureBytes Links

Trading Reference Links

Try this:
Condition1 = (spread_B - spread_B[LongLen])/spreadB > FactorLong ;   {For
Long entry}
Condition2 = (spread_B - spread_B[Shortlen])/spreadB < FactorShort;   {for
short entry}

Where LongLen,ShortLen is from 1 to RatioLen.
Where FactorLong is 0 to ?? and FactorShort is 0 to -??

This provides 3 optimization parsm to run against......
never assume the short side "profiles" (behaves) the same as the long side.

Try running your RatioLen to a larger number as well.

> -----Original Message-----
> From: Barry Silberman [mailto:barry@xxxxxxxxxxxxxxxxxxxxx]
> Sent: Saturday, March 04, 2000 12:25 AM
> To: omega-list@xxxxxxxxxx
> Subject: Help with EL for relative strength of stock vs sector
>
>
> In trying to backtest  improvements to entries for EOD trading
> with equities
> I came up with the following code to measure relative strength of an
> individual stock (data1) as compared with a sector (Data2).  Although the
> code seems to work, it suprisingly improves the entries only marginally.
>
> Can someone tell me if there is a flaw in the reasoning or a
> better way to
> approach this concept of relative strength.
>
> The code I'm using is as follows:
>
> {Sector Strength Filter
> Data1 = individual stock
> Data2 = sector  }
>
> INPUTS: RatioLen(5);
> Variable: spread_B(0), DataOne(0), DataTwo(0);
>
> DataOne = xaverage(close data1, RatioLen);
> DataTwo = xaverage(close data2, RatioLen);
>
> If DataTwo <> 0 then
> Spread_B = DataOne / DataTwo;
>
> Condition1 = spread_B - spread_B[1] > 0 ;   {For Long entry}
> Condition2 = spread_B - spread_B[1] < 0;   {for short entry}
>
>
> Thank you.
>
> Barry
>
>
>
>
>