Page 1 of 2

Linear regression Channels

Posted: Thu Jun 15, 2006 11:43 am
by ian_uk
Thanks to Michal for a new forum ( and to Avery as I have joined from TRO..Stockfetcher forums). Has anyone any views on the best software or code for identifying positions in the linear regression channel. I am not yet a member of stockfetcher but it looks as though their service would be able to find stocks in the sort of positions described in this link

http://scans.marketgauge.com/help/LinRegStrategies.asp

(consolidations of the shorter 3 period linear regression against the loger term trend).

Regards

Ian

PS I will check the TS forum which I have just re-joined because of TRO's recent posts but probably not in time to find his postings!

Re: LR Cahnnels

Posted: Thu Jun 22, 2006 8:45 pm
by Capnpaul
Ian



Is this what you has in mind?

J Paul

DLL now attached

Regression Channel Trading

Posted: Fri Jun 23, 2006 10:44 am
by ian_uk
Many thanks J Paul that is very useful and a nice chart. My question was prompted by the work of Mel Raiman who has highlighted reversion to the trend trades at the wings of the channel.

Ian

LN Chnnls

Posted: Fri Jun 23, 2006 11:36 am
by moneymarkets
Thanks for posting the LN Chnnls.
I get a error ---Missing nxtval32.dll ?
Where can that be found?
Thanks

Posted: Fri Jun 23, 2006 12:23 pm
by Capnpaul
NXTVAL32(DLL).ZIP
Now available above. Please excuse the omission.

Posted: Fri Jun 23, 2006 12:33 pm
by moneymarkets
That fixed it.
Thanks a lot.
Good looking indicator.
This is turning out to be a excellent forum. :lol:

Re: Linear regression Channels

Posted: Fri Jun 23, 2006 2:21 pm
by Capnpaul
ian_uk wrote:. . . or code for identifying positions in the linear regression channel. . . .
Ian


In the CAT chart sub graph 2 depicts the current price as a percentage of standard deviation (%Alpha).

%Alpha = (Price – (LRValue raw [Length]) / StdDev (Price, Length));

%Alpha may be used as an alert for both profit taking and protective stops.

When the price = one standard deviation the % alpha = +100%; 1.5 deviations would be equivalent to 150%. If the price is minus one standard deviation the %Alpha = -100%, etc.

This %Alpha may also be found useful to scan in Radar Screen and can locate those stocks that are trading below, at or above standard deviation.

This chart of CAT shows the %Alpha indicator as the red line in the lower chart. Grey shadow lines are drawn at + 1 StdDev (100%) and -1 StdDev (-100%).

The current Linear Regression Trend Line is the center line on the candle bar chart. The outer channel lines are drawn 1 StdDev above (green) and 1 StdDev below (red) the (Current) Trend line.

Since the drawn trend line is current, the Standard Deviation lines are only correct for today. These two lines show the historic points where price penetrated beyond one StdDev.

The %Alpha presentation is a correct representation of the historic points in time, where the price was beyond 1 StdDev.



Ian, Is this what your looking for?

Posted: Fri Jun 23, 2006 9:34 pm
by moneymarkets
Capnpaul wrote:
ian_uk wrote:. . . or code for identifying positions in the linear regression channel. . . .
Ian


In the CAT chart sub graph 2 depicts the current price as a percentage of standard deviation (%Alpha).

%Alpha = (Price – (LRValue raw [Length]) / StdDev (Price, Length));

%Alpha may be used as an alert for both profit taking and protective stops.

When the price = one standard deviation the % alpha = +100%; 1.5 deviations would be equivalent to 150%. If the price is minus one standard deviation the %Alpha = -100%, etc.

This %Alpha may also be found useful to scan in Radar Screen and can locate those stocks that are trading below, at or above standard deviation.

This chart of CAT shows the %Alpha indicator as the red line in the lower chart. Grey shadow lines are drawn at + 1 StdDev (100%) and -1 StdDev (-100%).

The current Linear Regression Trend Line is the center line on the candle bar chart. The outer channel lines are drawn 1 StdDev above (green) and 1 StdDev below (red) the (Current) Trend line.

Since the drawn trend line is current, the Standard Deviation lines are only correct for today. These two lines show the historic points where price penetrated beyond one StdDev.

The %Alpha presentation is a correct representation of the historic points in time, where the price was beyond 1 StdDev.



Ian, Is this what your looking for?
Would you post the LR_Dual_Bnds_PctAv3 shown on above chart.
The two together looks good.
thanks

Posted: Fri Jun 23, 2006 9:50 pm
by ian_uk
J Paul thank you for the additions and explanation that was precisely what I was looking for. I really appreciate that.

With best regards

Ian

More on %a

Posted: Sat Jun 24, 2006 11:07 am
by Capnpaul
All

%a has many characteristics that are valuable for creating trading indicators.