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

Strategy based on scanner

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

    Strategy based on scanner

    HI,
    I am evaluating the product and I am impressed so far.
    Can the instruments on which a strategy should operate, be determined at runtime with some sort of scanner?
    Where, by scanner, I mean a set of conditions on the market as a whole.

    Let's say I wanted to take the 5 instruments which have performed better yesterday on a specific market and act upon them today.

    Is this possibile without coding a specific sorting algorhythm to compare opening and closing prices of each one by one?

    Best Regards.

    Andrea Farè.

    #2
    Andrea,

    Unfortunately not. You will need to specify which instrument it is that you want to run your strategy on at startup.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_Josh View Post
      Andrea,

      Unfortunately not. You will need to specify which instrument it is that you want to run your strategy on at startup.
      dear Josh,
      sorry to hear that, but thanks for the blazing fast reply!!

      Can you confirm that the complex option would still be applicable (by writing appropriate code)?

      - Loop through all instruments on the market (I mean actually specifying each single name)
      - Calculate their performance (percentage variation open/close)
      - Sort them by performance
      - Pick the first five
      - cycle through and open positions on each of them.

      Regards.

      Andrea.

      Comment


        #4
        Technically possible, but will be taxing on your computer system as that requires many computations. It will also depend on your data provider since not all of them will let you open that many data streams.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Hello Andrea,

          I have such a strategy running. The strategy analyzes 28 currency pairs (all pairs I'm subscribed to). The strategy calculates the performance (determined by 6 different indicator values) for each tick on each pair and my CPU (8 cores) is still bored, only memory is sometimes on its limit. But the real problem is the performance of NT when you try to debug such a strategy. Most of the time is spent to watch this annoying "Loading data" dialog. I really don't know why NT always downloads the same data again and again.

          However, when the development of your strategy is finished, you won't have any performance problem.

          Regards,
          Daniel

          Comment


            #6
            Daniel, not sure I follow, once downloaded data is stored in the database and is only requested again from the provider in those cases -

            BertrandNinjaTrader Customer Service

            Comment


              #7
              Hello Bertrand,

              correct, NT will load data when “Format Data Series” contains the current day. I'm always testing my strategies with current live data in Sim101 account, so NT loads all the data of the current day again and again.

              Would it help to create a workspace that holds a chart for each instrument? I haven't tested it yet, because I'm not sure if charts on inactive workspaces are actually updated.

              Regards,
              Daniel

              Comment


                #8
                Yes, this would be a good idea to try - the workspace is still active though just not 'in current view'.
                BertrandNinjaTrader Customer Service

                Comment


                  #9
                  Thanks for the hint Buthus,
                  Regards.
                  Andrea

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by morrnel, 05-12-2024, 06:07 PM
                  3 responses
                  34 views
                  0 likes
                  Last Post wzgy0920  
                  Started by FishTrade, Yesterday, 11:11 PM
                  0 responses
                  5 views
                  0 likes
                  Last Post FishTrade  
                  Started by Austiner87, Yesterday, 03:42 PM
                  1 response
                  21 views
                  0 likes
                  Last Post NinjaTrader_Manfred  
                  Started by cshox, Yesterday, 11:11 AM
                  2 responses
                  16 views
                  0 likes
                  Last Post cshox
                  by cshox
                   
                  Started by algospoke, Yesterday, 06:53 PM
                  0 responses
                  11 views
                  0 likes
                  Last Post algospoke  
                  Working...
                  X