Announcement

Collapse
No announcement yet.

draw extended lines in efs?

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

  • draw extended lines in efs?

    How to draw extended lines in efs?

  • #2
    Do you mean draw a line that extends past the current bar to the right? To do that you simply pass a positive x-axis coordinate for the end of the line.

    Example:

    To draw a line at $70 from the point 10-bars ago to the point 10 bars in the future -

    var nId = 0;

    drawLineAbsolute(-10, 70.0, 10, 70, PS_SOLID, 1, Color.blue, nId++);

    where nID is your unique tag value.

    Chris

    Comment


    • #3
      What I want is to draw a trend line after finding two local maximum points. Suppose I am drawing a trend line on $spx daily chart by connecting the Dec. High and Feb. High, if I draw the line using the "extended line" tool in advanced chart, the trend line will be automatically extended to each new bar. How can I do the same thing using efs? If use drawLineAbsolute or drawLineRelative, the line won't be extended beyond the two terminal points.

      Comment


      • #4
        You can get the same effect by redrawing the line on every NEWBAR and extending the line say 20-30 bars into the future. Therefore, you will always have a line projection that far. Since this is trend lines it makes sence to redraw after every newbar anyways as the major pivots may have changed (due to the current bar making a new high/low).
        Garth

        Comment

        Working...
        X