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

Instruments without data or that are unknown

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

    Instruments without data or that are unknown

    When Adding an instrument in NinjaScript or adding that same instrument to a chart, if the instrument is selectable from the Instrument List, how does one tell if the instrument is actually supported and data is available?

    For example, on NinjaTrader FXCM, the Forex instrument USDHUF is selectable in charts and Add-able in NinjaScript, but it has no data. On a chart, one can see that. In NinjaScript, how can one determine that?

    Messages in the Trace file:

    2018-03-26 17:12:43:301 ERROR: 2 NT FXCM 70906032 Demo: Failed to subscribe to instrument '$USDHUF': Unknown OfferID / bad symbol map
    2018-03-26 17:15:01:188 (2 NT FXCM 70906032 Demo) Data.Bars.GetBarsNow: instrument='$USDHUF' from='2018-03-20' to='2018-03-25' period=1 Min splitAdjusted=False dividendAdjusted=False bars=0 session='Forex'
    Why are instruments that are not receiving data from the broker included in the instrument list?

    Thanks.
    Multi-Dimensional Managed Trading
    jeronymite
    NinjaTrader Ecosystem Vendor - Mizpah Software

    #2
    Hello jeronymite,

    Thank you for your note.

    Upon making the Bars Request to the data provider you would learn whether or not an instruments data was provided.

    Via NinjaScript you could check whether an instrument is supported by a data provider with a bars request, and checking if there was NoError. The following link provides an example of this error check.


    Regarding your question about why instruments that are not supported by a data provider are showed in an instrument list, likely because in order to implement this a bars request would need to be made for each instrument in the list upon startup of NinjaTrader. If one has an instrument list with 3000 instruments, it would take quite a while for NinjaTrader to start up to implement the feature you suggest.

    It’s likely you could write unsupported logic which would delete instrument lists on shut down on NT, then upon startup, loop through a .txt file of symbols, make bars requests, upon no error, add these to an instrument list.

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

    Comment


      #3
      Instruments without data or that are unknown

      Thanks, Alan.

      I note that you have referred me to Help for NT8. I am using NT7. Can you advise on my query accordingly, please?

      Thanks.
      Multi-Dimensional Managed Trading
      jeronymite
      NinjaTrader Ecosystem Vendor - Mizpah Software

      Comment


        #4
        Hello jeronymite,

        My apologies. There would be no such method in NT7.

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

        Comment


          #5
          Instruments without data or that are unknown

          Thanks, Alan.

          Yes, I'm aware there is no supported way to do this in NT7.

          Can you advise on any unsupported way, please? I fully understand that "unsupported" is truly unsupported, so I would ask that if there is a way, even obscure or convoluted, please do let me know.

          At the very least, if there is a way, please explain an approach I can explore, no matter how unconventional it may be.

          Thanks.
          Multi-Dimensional Managed Trading
          jeronymite
          NinjaTrader Ecosystem Vendor - Mizpah Software

          Comment


            #6
            Hello jeronymite,

            I'm not sure how it could be done in NT7 or whether or not its even possible.

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

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by yertle, Yesterday, 08:38 AM
            7 responses
            28 views
            0 likes
            Last Post yertle
            by yertle
             
            Started by bmartz, 03-12-2024, 06:12 AM
            2 responses
            21 views
            0 likes
            Last Post bmartz
            by bmartz
             
            Started by funk10101, Today, 12:02 AM
            0 responses
            4 views
            0 likes
            Last Post funk10101  
            Started by gravdigaz6, Yesterday, 11:40 PM
            1 response
            8 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Started by MarianApalaghiei, Yesterday, 10:49 PM
            3 responses
            11 views
            0 likes
            Last Post NinjaTrader_Manfred  
            Working...
            X