Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Swing Indicator results incorrect when CalculateOnBarClose is false - Solution

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

    Swing Indicator results incorrect when CalculateOnBarClose is false - Solution

    The Swing Indicator produces different results when Live or in Market Replay when CalculateOnBarClose is false compared to COBC true.

    See attachment "NT7 Swing CalculateOnBarClose True vs False..." which demonstrates this bug.

    I have copied Swing Indicator provided by NinjaTrader to the indicator MySwing and corrected the problem.

    See attachment "NT7 MySwing CalculateOnBarClose True vs False..." which demonstrates the bug fix.

    Attached is the full source for MySwing that solves this problem.

    Please be aware that the Indicators CandleStickPattern and CandleStickPatternAll also use the Swing Indicator and will produce incorrect results with CalculateOnBarClose set to false. These can be fixed by coping those indicators and referencing MySwing instead of Swing.
    Attached Files

    #2
    Hello AusTrader,

    Thanks for your post.

    I have confirmed your observations.

    Thanks for your efforts to code and report.

    We will investigate further and will update this thread when we have further information.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Hello AusTrader,

      We have completed our review of this and have concluded that we will retain the current functionality of the Swing indicator as is.

      You are welcome to post your solution in the NinjaTrader forums file sharing area.

      Thank-you.
      Paul H.NinjaTrader Customer Service

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by algospoke, 04-17-2024, 06:40 PM
      3 responses
      26 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Started by bmartz, 03-12-2024, 06:12 AM
      3 responses
      27 views
      0 likes
      Last Post NinjaTrader_Zachary  
      Started by Aviram Y, Today, 05:29 AM
      2 responses
      8 views
      0 likes
      Last Post Aviram Y  
      Started by gentlebenthebear, Today, 01:30 AM
      1 response
      8 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Started by cls71, Today, 04:45 AM
      1 response
      7 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Working...
      X