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 usazencort, Today, 01:16 AM
          0 responses
          1 view
          0 likes
          Last Post usazencort  
          Started by kaywai, 09-01-2023, 08:44 PM
          5 responses
          603 views
          0 likes
          Last Post NinjaTrader_Jason  
          Started by xiinteractive, 04-09-2024, 08:08 AM
          6 responses
          22 views
          0 likes
          Last Post xiinteractive  
          Started by Pattontje, Yesterday, 02:10 PM
          2 responses
          21 views
          0 likes
          Last Post Pattontje  
          Started by flybuzz, 04-21-2024, 04:07 PM
          17 responses
          230 views
          0 likes
          Last Post TradingLoss  
          Working...
          X