• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy wizard conditions & actions profit-goal/stop-loss question

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

    Strategy wizard conditions & actions profit-goal/stop-loss question

    in the strategy wizard conditions and actions section, how do i set up a test to exit a position when a profit goal or stop loss is hit?
    so far, i have accomplished the following within the wizard ...

    protected override void Initialize()
    {
    SetProfitTarget("32 tick profit goal", CalculationMode.Ticks, 32);
    SetStopLoss("32 tick stop loss", CalculationMode.Ticks, 32, false);

    CalculateOnBarClose = true;
    }

    but i can't figure out what to do to set up the condition/action test.
    please advise.

    #2
    Hello Joemiller,

    Thank you for your note.

    When you use SetProfitTarget/SetStopLoss you will not need to set up a condition. When your entry order logic is triggered and your entry order filled, the stop and profit target will be submitted and working 32 ticks from your entry price.

    To run a test, you could use the Strategy Analyzer under Control Center>New Strategy Analyzer. You could also use the simulated data feed or market reply to test this strategy on the sim101 account.

    I’ve provided a link to the Strategy Analyzer section of our Helpguide:
    http://ninjatrader.com/support/helpG...asket_test.htm

    I would like to add, both your stop loss and profit target have different fromEntrySignal names, “32 tick profit goal” and “32 tick stop loss”, thus are going to be independent and untied to each other. You would want your entry signalName to be say, Entry32SL32PL and then use that name for both your stoploss and profit target so that they are all tied together.

    For example,
    EnterLong(“Entry32SL32PL”);
    SetProfitTarget("Entry32SL32PL ", CalculationMode.Ticks, 32);
    SetStopLoss("Entry32SL32PL ", CalculationMode.Ticks, 32, false);

    See Entry Methods section of our helpguide:
    http://ninjatrader.com/support/helpG...d_approach.htm

    I’ve included a links to our Helpguide as well as a Youtube video covering Strategy Wizard.

    Youtube: https://www.youtube.com/watch?v=FmBi...D7105&index=10
    Helpguide: http://ninjatrader.com/support/helpG...rd_screens.htm

    Please let us know if you need further assistance.
    Alan P.NinjaTrader Customer Service

    Comment


      #3
      thanks Alan.

      very helpful and much appreciated.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by signalworks, Today, 01:50 AM
      0 responses
      1 view
      0 likes
      Last Post signalworks  
      Started by danitralla, Today, 01:23 AM
      0 responses
      1 view
      0 likes
      Last Post danitralla  
      Started by superg3, Today, 12:33 AM
      0 responses
      3 views
      0 likes
      Last Post superg3
      by superg3
       
      Started by vppzepuq, Yesterday, 11:28 PM
      0 responses
      2 views
      0 likes
      Last Post vppzepuq  
      Started by Steve L, 05-25-2019, 10:04 PM
      1 response
      6 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Working...
      X