Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

aggressive vs passive limit orders.

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

    aggressive vs passive limit orders.

    I'm looking to clarify the way NT's Strategy Analyzer handles aggressive and passive limit orders.

    --Given I'm placing and EnterLongLimit() and my strategy has bid and ask data series.

    Here's what I expect should happen:
    1) If I set my long limit to be filled on the ask then this is an aggressive limit and NT's fill algo should fill at the ask as long as the ask is touched since this is a marketable limit. For example, if my long limit = 100 at the ask, then as soon as the ask touches 100 I should get filled.

    2) If I set my long limit to be filled on the bid then this is a passive limit and NT's fill algo should require a marketable limit.
    For example, if long limit = 100 and bid = 100 my order would still only get filled if the market went ask =100 since only at this point would we have a marketable limit.

    Are these assumptions regarding the Strategy Analyzer correct?

    #2
    Hi bluelou,

    This depends on how you have written your strategy.

    If you are using a secondary data series that is using the MarketDataType.Ask / .Bid, then yes this would be correct.

    From my experience, buy orders do not involve the Ask.. If you have the limit set to the Ask price, the bid/last will still need to meet the limit for it to fill.

    If you are trying to use GetCurrentAsk()/GetCurrentBid, these do not work in backtest.
    http://www.ninjatrader.com/support/h...currentask.htm
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      ChelseaB,
      I just want to make sure that it's possible to make a conservative fill assumption in Strategy Analyzer where I can cross the spread and get my long order filled at the ask. You're saying that, yes, this is possible, correct? Importantly, since the long limit is a marketable limit at the ask I want to confirm that NT will fill my order at ask if touched, not at trade through. Please confirm.

      Thx,
      Lou


      Originally posted by NinjaTrader_ChelseaB View Post
      Hi bluelou,

      This depends on how you have written your strategy.

      If you are using a secondary data series that is using the MarketDataType.Ask / .Bid, then yes this would be correct.

      From my experience, buy orders do not involve the Ask.. If you have the limit set to the Ask price, the bid/last will still need to meet the limit for it to fill.

      If you are trying to use GetCurrentAsk()/GetCurrentBid, these do not work in backtest.
      http://www.ninjatrader.com/support/h...currentask.htm

      Comment


        #4
        Hi bluelou,

        The Strategy Analyzer will not automatically pull in ask and bid prices.

        If the limit order is within the high and low of the bar it will fill.

        To increase accuracy you can add a secondary series of 1 tick (ask or bid), and place the order to that secondary series so that the ask or bid tick data will fill the order.

        Below is a link to a reference sample that shows how to add intra-bar granularity.
        http://www.ninjatrader.com/support/f...ead.php?t=6652
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          ChelseaB,
          Okay, so let's say I have a 1-second bid data series and a 1-second ask series in Strategy Analyzer and I'm placing a long limit at the ask. Will my marketable limit be filled, i.e., will the ask be lifted if touched in a 1-sec ask data series? If so, then I'll know that if it's not happening it's a problem on my end and not NT.

          Comment


            #6
            Hello bluelou,

            The 1 tick bid and ask series will need to be added to your strategy with the Add() call and the orders will need to be placed to the proper series.

            The 1 tick bid and ask historical data will also need to be downloaded to your computer.

            http://www.ninjatrader.com/support/h...s/nt7/add3.htm

            http://www.ninjatrader.com/support/h...inprogress.htm

            EnterLongLimit(int barsInProgressIndex, bool liveUntilCancelled, int quantity, double limitPrice, string signalName)
            http://www.ninjatrader.com/support/h...rlonglimit.htm

            Yes, if done correctly, your buy limit orders should fill at the ask price (of the added dataseries) and the sell limits should fill at the bid price (of the added dataseries).
            Chelsea B.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by fx.practic, 10-15-2013, 12:53 AM
            5 responses
            5,406 views
            0 likes
            Last Post Bidder
            by Bidder
             
            Started by Shai Samuel, 07-02-2022, 02:46 PM
            4 responses
            98 views
            0 likes
            Last Post Bidder
            by Bidder
             
            Started by DJ888, Yesterday, 10:57 PM
            0 responses
            8 views
            0 likes
            Last Post DJ888
            by DJ888
             
            Started by MacDad, 02-25-2024, 11:48 PM
            7 responses
            160 views
            0 likes
            Last Post loganjarosz123  
            Started by Belfortbucks, Yesterday, 09:29 PM
            0 responses
            9 views
            0 likes
            Last Post Belfortbucks  
            Working...
            X