Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Custom candlestick formula

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

    Custom candlestick formula

    How can i execute the following custom candlestick identification formula in ninjascript

    (O1>C1) AND (C-O)>=0.7*(H-L)AND (C>O1) AND (H-L)>=1.5*(AVGH10-AVGL10)AND (H1-L1).>=0.7(AVGH10-AVGL10) AND (O1-C1).=)0.7*(H1-L1)

    where O1 indicated open 1 bar ago and so on .

    #2
    Hello,

    Thank you for the question.

    This would require some manual programming, I will post the items below in which would be needed to complete this statement if you want to try this yourself. Otherwise this would need to be created using NinjaScript.

    The various syntax you would need for this would be located in the NinjaScript reference here: http://ninjatrader.com/support/helpG..._reference.htm

    This statement would require a few different items, for the values you would use such as the Open of 1 bars ago, that would be:

    Code:
    Open[1]
    The basic syntax for if statements can be located in the sample here: http://ninjatrader.com/support/helpGuides/nt7/close.htm

    To combine multiple items, you could use the && sign which would look like the following when used in an if statements:

    Code:
    if (Close[0] > Close[1] && Close[1] > Close[2])
    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by GussJ, 03-04-2020, 03:11 PM
    11 responses
    3,227 views
    0 likes
    Last Post xiinteractive  
    Started by andrewtrades, Today, 04:57 PM
    1 response
    13 views
    0 likes
    Last Post NinjaTrader_Manfred  
    Started by chbruno, Today, 04:10 PM
    0 responses
    7 views
    0 likes
    Last Post chbruno
    by chbruno
     
    Started by josh18955, 03-25-2023, 11:16 AM
    6 responses
    440 views
    0 likes
    Last Post Delerium  
    Started by FAQtrader, Today, 03:35 PM
    0 responses
    12 views
    0 likes
    Last Post FAQtrader  
    Working...
    X