# Tag Info

Accepted

### How can one effectively approximate the fill portion of a limit order in a FIFO order book given it's recent state?

In my opinion, instead of developing an analytical model, it's better to evaluate this probability directly from the data. Place your simulated orders at different price levels, and check whether and ...
• 1,022
Accepted

### Algorithmic Execution Literature/References

You now have four reference books for algo trading Market Microstructure in Practice (L and Laruelle) for an introduction and microstructure related aspects The Financial Mathematics of Market ...
• 12.1k

### How is market buy order executed when meeting both market sell order and limit sell order?

Two (or more) orders arriving at the same time makes no difference for an exchange's matching engine, the buy orders execute against sell limit orders, and the sell orders execute against buy limit ...
• 4,338

### Send TRAIL STOP order when price hits a certain level, with IB TWS

I think what you are looking for is an Adjustable Stop Orders (https://www.interactivebrokers.com/en/index.php?f=574). Using adjustable-stop-order you can limit your losses in case the price falls ...
• 179
Accepted

### Standard ways of simulating order books

Nowadays (4 years after your question...), the best way to simulate orderbook dynamics is probably to implement the Queue Reactive model, from Huang, Weibing, C-A L, and Mathieu Rosenbaum. "...
• 12.1k
Accepted

### Achieving an even distribution of orders in the queue

Suppose your target participation rate is 1/11 ~ 9%. At each price level, whenever someone puts a limit order of size 10, you put a limit order of size 1 right after him. Whenever someone cancel an ...
• 56
Accepted

### How are piled-up orders matched?

Each exchange is a bit different, especially the listing exchange vs others, so no one answer. This should add a bit of color on the Nasdaq opening auction -
• 454
Accepted

### Does all (or any) exchange eats the positive difference between a buy order and a ask order?

What your describing is a simple limit-order book. Bob submits a limit order to buy 10 shares at \$101 so he will get filled for 5 @ 100 and 5 @ 101 and have a VWAP of \$100.5. If a broker or ...

### Optimal execution of illiquid securities

Please note that my answer is primarily opinion/experience based. If it is not appropriate I will take it down or edit accordingly. How should I begin to think about optimal execution given a choice ...
• 4,338
Accepted

### Fill prices on limit and market orders

In the first case it is a "race condition": whichever order is received first (even if it is only one microsecond before the other) will populate the Book and the second limit order will execute ...
• 11.2k
Accepted

### Python everywhere but where do they execute orders?

IBPy + IB Gateway + TWS and you can send order to any interactive brokers, how to setup

### Order Replacement Trade-off for a Market Maker

they are now plenty of academic resources to address the point of interacting with liquidity via limit orders: Stochastic control is the best way (it's optimal!) but you need a model of liquidity ...
• 12.1k
Accepted

### Exchange order matching system/core for local testing

I am not aware of any such service but simulating exchange behavior for backtest is very challenging given irregular order arrival and their impact and hidden orders. Even the paper trading service’s ...
• 444
Accepted

### Determine market and ice-berg order types from live trade and quote data

In general you cannot determine this information from the public data feeds- the purpose of Iceberg orders in particular is to be hidden and difficult to detect. Also, there isn't really a ...
• 221

### What is meant by "a stop order may trigger another stop order?"

If a stop order triggers (let's say a stop sell order) it adds an additional sell order which, if executed, can push the price down which can trigger more stop sell orders. There is no possibility ...
• 131
Accepted

### How were High Frequency Traders able to front-run in this example from Flash Boys?

Michael Lewis is either being disingenuous here or exercising creative license with this story. Spreads are wider than the edge of absorbing wholesale customer flow. Even if we take this to a further ...
• 304
Accepted

### What approaches are there for keeping local and remote order books in sync?

My 3 points for you: Earlier checks like pre-compliance checks for orders are usually performed. Three different types of orders are correctly recognized - i.e. proposed orders but not routed, ...
• 80

### Send TRAIL STOP order when price hits a certain level, with IB TWS

You would create an "Alert" in TWS that submits the trailing order when some set of market conditions are met. It's confusing because this is really a trigger, but IB calls it an alert. ...

### Algorithmic Execution Literature/References

I think that among others, Empirical Market Microstructure is a good book to start with. For more recent theories, you can find articles from q-fin.TR subsections ...
• 712

### Question about order book and single player interference

This is a complex question. First of all, you need to know that orderbook manipulation is illegal. That being said, I can rephrase you question as: given an orderbook say a new sell order of size \$...
• 12.1k
Accepted

### How does a Stock Exchange Provider implement a Stop-Loss Order?

It depends: Does the exchange support Stop orders? Some do, some don't. You can find it in exchange's documentation. If the answer is "no" but your broker offers it, then Stop orders are managed ...
• 1,022

### Accurate model but execution in backtesting is losing money

Can I ask what type of backetest you are using? Is it an event-driven backtest or a simple for-loop backtest. Depending on whether you wrote your own or are using a library for it, try and analyse a ...

### Market makers order execution on the order book

Owen, designated market makers in general are required to send in a two sided market (a bid and and offer) within a certain width for a certain percentage of the time. There's no obligation to cross ...
• 2,613

### Market Making Formulation

First of all, there is a more general version of Avellaneda-Stoikov here: Guéant, Olivier, C-A L., and Joaquin Fernandez-Tapia. "Dealing with the inventory risk: a solution to the market making ...
• 12.1k

### Difference between Order Expire and Order Done for Day (DFD)

Order expired may be sent when a Good Til Date (GTD) order reaches its expiration date or a Good Til Cancel (GTC) order reaches its maximum age. That maximum age may be broker-specific and even ...
• 2,900

### Why does Canada allow merely 9% spread between the trailing stop price and its limit offset?

Stop buy orders are dangerous: you can overpay for a stock when it spikes up (partly from your and others' stop orders all kicking in at the same time), only to have it come back down when the flurry ...
• 11.2k

### Execution Strategies

What are some of the ways one can improve execution model of a market making strategy? If your market making strategy is delta-neutral two-sided passive quoting, then your execution quality is really ...
• 103
Accepted

### Do IOC Orders Stay on the Order Book for Any Period of Time

They will not stay and therefore your conclusion is correct. The behaviour you describe can be achieved by setting a time in force on the order or manually canceling after some time.
• 8,552
1 vote

### How does a Stock Exchange Provider implement a Stop-Loss Order?

It is important to note the difference between "regular" buy / sell orders and "stop-loss" orders in terms of how they enter the order book. Regular buy/sell orders enter the order book immediately ...
• 6,098

Only top scored, non community-wiki answers of a minimum length are eligible