Announcement

Collapse
No announcement yet.

Draw trend line and get values back

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

  • Draw trend line and get values back

    Hi there,

    is there a way to draw a trend line via script and have access to the variables. For example, if close(0) is greater than "trend line"?

    Many thanks

  • #2
    KingSerk
    You can use the addLineTool() function to draw lines (see the link to the related article in the EFS KnowledgeBase).
    As to their values at each bar you will need to calculate it yourself. Not a difficult task since you know the start and end points anyhow. Search the forum as there should already be examples on how to do this
    Alex


    Originally posted by KingSerk View Post
    Hi there,

    is there a way to draw a trend line via script and have access to the variables. For example, if close(0) is greater than "trend line"?

    Many thanks

    Comment


    • #3
      Thanks Alex, I'm not sure what term to use for the search. What should I use?

      Thanks

      Comment


      • #4
        KingSerk
        Try searching for terms like addlinetool* or trendline*
        Alex


        Originally posted by KingSerk View Post
        Thanks Alex, I'm not sure what term to use for the search. What should I use?

        Thanks

        Comment

        Working...
        X