Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

help with complex strategy

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

    help with complex strategy

    Hi Gang,

    I am developing a complex strategy into Ninja trader for people to use and was wondering if anyone can help me with the following questions:

    - I need to develop a strategy that uses an index [S&P 500] as a trigger mechanism, support and resistance levels are defined in this index

    - Trades get fired when certain conditions are met near support or resistance levels and these can be for 1 of 2 possible instruments, 1 is a long ETF and the other is a short ETF

    - The strategy must have access to time and sales data for it to be accurate and mimimize risk, tick data may suffice or at least data down to the 1 second level

    Is this possible with Ninja Trader, we have tried doing this with Trade Station but ran into several limitations with Easy Language that we were unable to overcome.

    Thanks!

    shawn

    #2
    Shawn, the points you list are all possible with NinjaTrader.
    AustinNinjaTrader Customer Service

    Comment


      #3
      Thanks austin

      Can you give me a hint as to where to look, the samples seem to show a strategy link to a chart for a single equity. Where can I find some info on building an advanced strategy like the one I am reffering to?

      Thanks!

      Comment


        #4
        Please see: http://www.ninjatrader-support.com/H...ameInstruments

        Time and Sales information can be found through manipulation of the OnMarketData() method.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          thanks!

          Hi Josh,

          Thanks that is very helpful and exactly what I've been trying to figure out...that should solve the time and sales data issue.

          So if I attach an index to the strategy, say S&P500 overriding OnMarketData() will give me access to MarketDataType.Last perfect!

          Now the tricky part, if I want to fire a trade for either SDS or SSO can you point me in the right direction? This strategy will either be LONG SSO or LONG SDS depending on market conditions and support resistance levels on the S&P index.

          I am assuming I will have to write my own code to manage position information within the script or will Ninja be able to maintain which postion I am in?

          Thanks for your help!

          shawn

          Comment


            #6
            Shawn,

            You need to add the index as a secondary bars series. If you want to be able to trade two different instruments you need to add the extra as another bars series as well.

            You can then choose which BarsInProgress context you want to trade to. For instance: http://www.ninjatrader-support.com/H...EnterLong.html
            You have this signature:
            EnterLong(int barsInProgressIndex, int quantity, string signalName)
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              Great, I'll hammer on this for a bit and see what comes out...

              Thanks!

              shawn

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
              0 responses
              649 views
              0 likes
              Last Post Geovanny Suaza  
              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
              0 responses
              370 views
              1 like
              Last Post Geovanny Suaza  
              Started by Mindset, 02-09-2026, 11:44 AM
              0 responses
              109 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
              0 responses
              573 views
              1 like
              Last Post Geovanny Suaza  
              Started by RFrosty, 01-28-2026, 06:49 PM
              0 responses
              576 views
              1 like
              Last Post RFrosty
              by RFrosty
               
              Working...
              X