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:


    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:


    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 timmbbo, Today, 08:59 AM
      1 response
      2 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by KennyK, 05-29-2017, 02:02 AM
      2 responses
      1,279 views
      0 likes
      Last Post marcus2300  
      Started by fernandobr, Today, 09:11 AM
      0 responses
      0 views
      0 likes
      Last Post fernandobr  
      Started by itrader46, Today, 09:04 AM
      1 response
      3 views
      0 likes
      Last Post NinjaTrader_Clayton  
      Started by bmartz, 03-12-2024, 06:12 AM
      5 responses
      33 views
      0 likes
      Last Post NinjaTrader_Zachary  
      Working...
      X