Announcement

Collapse
No announcement yet.

Multi Time Frame use of Linear Regression Channel Tool/Indicator

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Multi Time Frame use of Linear Regression Channel Tool/Indicator

    I have programmed the attached indicator to emulate all the features of eSignal's Linear Regression Tool. However there are 2 issues which on the second in particular I would appreciate assistance:-

    LR.efs

    1. This issue has been raised years ago, eSignal tool uses Standard Error instead of Standard Deviation for computing the channels. I am not too bothered about this as my preference is to use Raff anyway. However in case anyone checks the use that is reason of difference between the 2.

    2. I tried to incorporate multi time frame features so that a channel could be drawn from a higher time frame into a smaller one. However it will not draw right because it uses the bars in lower time frame to draw the channels however computes correctly from higher time frame as all the values are correctly referenced.

    In addition if anyone has suggestions or code improvements to make more efficient/useful any feedback would be welcome.

    Robert

  • #2
    I would like to demonstrate the issues with using the efs in multi timeframe mode

    Here are 2 charts side by side one with 15min TF and the other 5min TF each using the indicator in its own timeframe with 15 period lookback and Raff channels based on hlc3 and will match the drawn tool from eSignal

    INITIAL LR drawn using own TF
    Click image for larger version

Name:	Initial Own TF.png
Views:	1
Size:	62.8 KB
ID:	242880


    Then on the 5min chart the interval is changed to 15min and the result is that the slope is right (as per look on 15min chhrt) but literally is only drawn 15 bars back on the lower timeframe instead of 15 bars equivalent from higher timeframe

    COMPUTED 15min TF plotted in 5min chart
    Click image for larger version

Name:	Computed MTF.png
Views:	1
Size:	67.8 KB
ID:	242881


    I have been experimenting with new code given in a separate post to make the channel from a higher timeframe draw correctly in the lower timeframe as per the screenshot. However the code is becoming unweildly and it should be easier than this to make this work. so if anyone has any ideas for cleaner code I would appreciate it

    DESIRED higher time frame plotted in lower timeframe
    Click image for larger version

Name:	Desired MTF.png
Views:	1
Size:	74.0 KB
ID:	242882

    Comment


    • #3
      The new code is attached.

      The key is using getBarStateSymbol() and passing the symbol/interval as the higher timeframe in current (lower time frame) chart.

      There still needs to be some tweaks for the forward projection lines to make it look right when comparing the channel on the higher time frame vs the same thing on the lower time frame. I am sure there must be a cleaner way to do this. If anyone knows please post.

      Robert

      LR.efs
      Last edited by rcamrn123; 07-30-2013, 12:20 PM.

      Comment


      • #4
        Question to Esignal Development Group (as per request):-

        What is the correct coding to use to draw lines between 2 points from an external interval (ie higher time frame) onto a chart (ie with a lower time frame) that will be correctly represented in the current chart.

        Robert

        Comment


        • #5
          Robert
          My reply to you in this thread applies also here
          Alex


          Originally posted by rcamrn123 View Post
          Question to Esignal Development Group (as per request):-

          What is the correct coding to use to draw lines between 2 points from an external interval (ie higher time frame) onto a chart (ie with a lower time frame) that will be correctly represented in the current chart.

          Robert

          Comment

          Working...
          X