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

Requesting Help: MA Crossover Strategy from a Noobie

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

    Requesting Help: MA Crossover Strategy from a Noobie

    Hello. First, thank you for taking the time to read over my questions. I have been reading through this forum and a lot of it is very overwhelming for me (obviously I am not a coder by ANY stretch of the means!).

    I have a basic MA crossover strategy (EMA 10/WMA 16) that I am satisfied with the backtesting results. I have a few questions, and again I sincerely apologize for how ignorant I am sounding and how ignorant I am being...however, that is why I am here! To talk to subject-matter experts.

    Question 1: On the Strategy Analyzer, the "Max. Drawdown" row, is that to be understood that out of all of the theoretical trades the analyzer took, that is the number of Ticks a particular trade went before being closed out/or flipping back into profit? Meaning: Max. Drawdown = -7 (the largest drawdown would have been negative 7 ticks)?

    Question 2: I used the Strategy Builder, and analyzed it on the Heiken Ashi 1 Minute chart. Again, I am satisfied with the results (net profit/gross loss). What must I do in order to make this strategy automated (i.e. click a few buttons, turn it on so it trades on its own, taking profits, etc.)?

    Question 3: Is there a way I can include a trailing stop loss (say maybe 3 ticks in profit above price entry point once the trade goes 10 ticks in the positive) into my current strategy?

    The problem I am running into is that when I turn the strategy on, it only takes losses ("order canceled") and it is not taking any wins.

    I am not sure why on the Strategy Analyzer it is showing very good results, while when I turn it on, it has nothing but losses and does not take any wins. I understand there may be a certain amount of consecutive losses in a row, and I understand the Strategy Analyzer will take every single trade per the parameter's given it...but I am hitting my head against a wall here and am totally lost.

    Again, I sincerely appreciate your patience with me! Thank you so very much for your time, assistance and knowledge!

    Here is a screenshot of the code:

    Last edited by MalachiBond; 05-11-2020, 05:10 PM.

    #2
    Also, when I do turn on the strategy...will it stay turned on if an order is closed/filled, or do I need to manually turn it on for each order?

    Comment


      #3
      Hello MalachiBond,

      Thanks for your post and welcome to the NinjaTrader forums!

      Please note that we have already responded to your e-mail on the same subject.

      1. For the Max DrawDown, correct that would be for all trades. Please see the help guide section " Understanding Max. Drawdown" on this page for further details: https://ninjatrader.com/support/help...efinitions.htm

      2. To run a strategy on a chart you must enable it. Please see the help guide here: https://ninjatrader.com/support/help...t_strategy.htm

      3. The Strategy Builder provides a simple trailing stop. On any given order you can use either a fixed stop loss or a Trailing stop but not both as the trailing stop would then be ignored. The trail stop will start at whatever number of ticks you specify and will remain behind the price that amount and will not go backwards, so for every tick of profit, the stop will move closer 1 tick. Please note that to use the trail stop your strategy must be run with Calculate.OnEachTick lor Calculate.OnPriceChange. Please see the help guide here: https://ninjatrader.com/support/help...ttrailstop.htm

      The Heiken-Ashi presents false data concerning actual price movement. We do not recommend using Heiken-Ashi bars in the strategy analyzer because it will provide misleading results because the analyzer assumes the bars are what price really is. We do recommend testing your strategy using Playback with market replay data as this will provide tick by tick data and in the case of the Heiken-Ashi bars will better represent real time trading. Reference: https://ninjatrader.com/support/help...connection.htm

      When you enable the strategy on live data, it will continue to trade until it becomes disabled. It would become disabled in the event of an error, a disconnection of the data feed (loss of internet), or turning off the strategy manually, or shutting NinjaTrader down. It will not restart automatically.

      A good practice is to always observe the "Log" tab of the control center when you enable/run a strategy as any run time errors or warnings will be shown there. the log tab is also a good place to look when anything is not working as expected.


      Paul H.NinjaTrader Customer Service

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Segwin, 05-07-2018, 02:15 PM
      10 responses
      1,768 views
      0 likes
      Last Post Leafcutter  
      Started by Rapine Heihei, 04-23-2024, 07:51 PM
      2 responses
      30 views
      0 likes
      Last Post Max238
      by Max238
       
      Started by Shansen, 08-30-2019, 10:18 PM
      24 responses
      943 views
      0 likes
      Last Post spwizard  
      Started by Max238, Today, 01:28 AM
      0 responses
      9 views
      0 likes
      Last Post Max238
      by Max238
       
      Started by rocketman7, Today, 01:00 AM
      0 responses
      7 views
      0 likes
      Last Post rocketman7  
      Working...
      X