Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Sample MA Crossover Strategy Commissions

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

    Sample MA Crossover Strategy Commissions

    Hi,

    I am having a hard time figuring this out. I have a custom strategy where basically I duplicate the Sample MA Crossover, but instead of using EnterShort() and EnterLong(), I build a "trend signal" to send an exit order (ExitShort, ExitLong), and when this order is filled I send a separate enter order (EnterShort, EnterLong) - according to the trend signal generated.

    I use the "include commission" option in the strategy analyzer to calculate performance accurately.

    However am having a very significant difference of results between these two strategies. Is it possible that the Sample MA Crossover calculates the commission only once when sending an order? In real life the broker calculates the commissions twice in case of such signal, right?

    Thanks for helping me to figure this out.

    #2
    1 charge to buy, another 1 charge to sell

    Comment


      #3
      Hello RT001,

      Commissions applied to the account (Sim101 account if backtest) would be applied to all strategies using include commissions, including the SampleMACrossOver included with NinjaTrader.

      If the results are different, this would imply the orders are being submitted at different times or prices. Different orders, different results.

      You can debug the script using Print() and TraceOrders to understand what is different.

      Below are links to forum posts that demonstrate.
      https://ninjatrader.com/support/foru...nce#post100192
      https://ninjatrader.com/support/foru...121#post791121
      Chelsea B.NinjaTrader Customer Service

      Comment


        #4
        Thank you very much ChelseaB, it's much appreciated. I will go through the posted information in the next days.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by doozytrader, 10-25-2021, 07:53 PM
        7 responses
        181 views
        1 like
        Last Post Wessel
        by Wessel
         
        Started by sdp1969, 04-22-2021, 08:05 AM
        7 responses
        177 views
        4 likes
        Last Post Wessel
        by Wessel
         
        Started by Tradexxx, 01-20-2021, 12:19 AM
        6 responses
        246 views
        0 likes
        Last Post travelinman  
        Started by UltraNIX, Today, 04:38 AM
        0 responses
        3 views
        0 likes
        Last Post UltraNIX  
        Started by gvaughn, Today, 02:32 AM
        1 response
        3 views
        0 likes
        Last Post NinjaTrader_Jason  
        Working...
        X