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

MasterInstrument.Margin and MasterInstrument.Margin2

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

    MasterInstrument.Margin and MasterInstrument.Margin2

    Hi,

    I tried to search for it in the documentation and forum and there is no info.

    1. What is the Margin and Margin2 properties and from where NT takes its values?

    2. Also what is the idea behind MasterInstrument compare to Instrument.
    I understand that this is a class inside a class but what is the design idea behind it?

    Thanks!

    #2
    freewind, those are unfortunately unsupported properties, we support what is documented in our helpguide (margin though is set in the instrument manager).

    The compare method is useful to avoid running into floating point accuracy issues while comparing price values.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Hi Bertrand,

      In question 2 I wanted to understand the different between Instrument class and MasterInstrument class. The name MasterInstrument is confusing and I don't understand from where it take the data?

      Thanks again for your time.

      Comment


        #4
        I see, the master instrument is the one defined in your instrument manager, for a futures contract this would be for example the 'raw' data needed to define it (point value, exchange, map, roll period etc) - the actual instrument on the chart is then represented by the instrument class, i.e. this would be the futures contract with a specific expiry that you could execute on.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          Thank you for an amazing support!

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by aussugardefender, Today, 01:07 AM
          0 responses
          3 views
          0 likes
          Last Post aussugardefender  
          Started by pvincent, 06-23-2022, 12:53 PM
          14 responses
          238 views
          0 likes
          Last Post Nyman
          by Nyman
           
          Started by TraderG23, 12-08-2023, 07:56 AM
          9 responses
          383 views
          1 like
          Last Post Gavini
          by Gavini
           
          Started by oviejo, Today, 12:28 AM
          0 responses
          4 views
          0 likes
          Last Post oviejo
          by oviejo
           
          Started by pechtri, 06-22-2023, 02:31 AM
          10 responses
          125 views
          0 likes
          Last Post Leeroy_Jenkins  
          Working...
          X