Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy builder.

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

    Strategy builder.

    I'm currently running my own custom strategy using alerts that activate ATM strategy.
    building it into a Strategy with Strategy builder. Its got multi time frames in conditions and actions. Asking in advance. Once its done will. I be able to use it on different instruments like gold futures and oil futures. Or will I need to build a new strategy for each instrument?

    #2
    AddDataSeries("AAPL", BarsPeriodType.Minute, 1); , : Instrument and Time frame. dependent on what has been added to the code.

    Comment


      #3
      Hello Derekr995,

      Thanks for your post and welcome to the NinjaTrader forums!

      My reply will be based on your use of the "Strategy Builder", if you really are programming in Ninjascript, please clarify and I can update my reply to what you are using.

      Regarding, " I be able to use it on different instruments like gold futures and oil futures. Or will I need to build a new strategy for each instrument?"

      This would be very dependant on how you have added the data series in the Strategy Builder. If you checked "Use Primary series" for each added data series, then yes your strategy will work on whichever instrument/chart you run the strategy. The "Use primary instrument" means it will take the chart's instrument and add data series based on that instrument.

      If you did not check the "use primary instrument" then your strategy would load data based on that added instrument and not what chart the strategy is applied to, so it would not work as expected.
      Paul H.NinjaTrader Customer Service

      Comment


        #4
        Thank you for that. Use Primary series worked great. But I have another issue with the strategy rearming after my target or stop is filled calculating on each tick.
        With an alert I could keep it from rearming for 300 seconds or on bar close. By that time the parameters for entry are gone. So it doesn't try taking another order in the same candle stick

        Comment


          #5
          Hello Derekr995,

          Are you seeing that its taking another Entry on the same bar and then following with targets? If its the entry which is being triggered again or your whole logical sequence you can use BarsSinceEntryExecution or BarsSinceExitExecution for this:




          In the builder these are found under Misc -> Bars since entry or Misc -> BarsSinceExit

          These generally need to be used in a group condition where you chose If Any of the conditions are true for the group. One of the conditions can check if the bars since entry was -1 meaning no entry was seen. Another condition can check that the bars since entry was greater than the number of bars you want to avoid having another entry such as 1. If the value is -1 or greater than 1 you can place a trade again.


          I look forward to being of further assistance.
          JesseNinjaTrader Customer Service

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by gravdigaz6, Today, 11:40 PM
          0 responses
          4 views
          0 likes
          Last Post gravdigaz6  
          Started by MarianApalaghiei, Today, 10:49 PM
          3 responses
          9 views
          0 likes
          Last Post NinjaTrader_Manfred  
          Started by XXtrader, Today, 11:30 PM
          0 responses
          3 views
          0 likes
          Last Post XXtrader  
          Started by love2code2trade, Yesterday, 01:45 PM
          4 responses
          28 views
          0 likes
          Last Post love2code2trade  
          Started by funk10101, Today, 09:43 PM
          0 responses
          9 views
          0 likes
          Last Post funk10101  
          Working...
          X