Hot answers tagged

15 votes

why is there a cancel/replace message in FIX?

Order Cancel-Replace might save you from losing priority in the book (for instance when cancelling some of the remaining shares - check the venue rules!). The communication overhead is very ...
  • 758
8 votes

What are the main types of orders on an exchange?

As @chrisaycock mentioned, there's many permutations of parameters, especially when it comes to venue routing instructions, so it's hard to write an exhaustive list. But most of the time, the ...
  • 1,820
5 votes

Limit Order Book disaster recovery technique

For data on a given single host, a common architecture is to write the data onto a queue (could be multi-consumer or single consumer), and have an asynchronous writer that reads it off and persists it ...
  • 1,820
4 votes

Order Execution Algorithms

To slice up an order you can use several execution strategies. TWAP which will execute small slices of your order over a time period VWAP which will spread your order over time and try to minimize ...
  • 1,349
4 votes
Accepted

Order Execution Algorithms

Most of the big players offer a suite of execution algorithms for big orders, as seen in this listing from Credit Suisse. Very generally speaking, the algorithms will have a pedigree going back to ...
  • 14.5k
3 votes

How to model bracket orders?

You will need an entry and then a "Grouped" stop loss and take profit (one cancels other). An implementation of this exists in quantstrat in R called ordersets. Documentation and source code can be ...
2 votes
Accepted

Difference between real and expected average transaction price of an order?

Some orders may be hidden, I guess your expected result is that you don't consider hidden orders as you can't see them in the limit order book, and the real result includes hidden orders.
2 votes

Difference between IOC and FOK orders

Generally FOK means Fill Entirely or Cancel. IOC means "Fill what you can and then cxl the remainder"
  • 2,458
2 votes
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 ...
  • 962
2 votes

What are the main types of orders on an exchange?

I wouldn't say there are 150 order types. Maybe 150 permutations of various parameters. There also isn't going to be a single list for all exchanges because each trading venue experiments with its ...
  • 9,689
1 vote
Accepted

Stock market simulator coding problem

The price is given per unit, the quantity gives you the available size or depth. The actors of the market will give you the lowest at which they are ready to sell and highest at which they are willing ...
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 ...
  • 5,366
1 vote

what happens when a stock price gaps over buy/sell stop order?

Generally speaking, you are correct. The broker will usually close at the first opportunity at or beyond the critical level. But beware the generalities! You need to check the T&Cs to make sure ...
  • 4,961
1 vote

what happens when a stock price gaps over buy/sell stop order?

You wrote 'since my sell stop order is a limit order it will get hit and then change into a market order to be filled at the "best available price" '. That's generally correct, about what will happen....
  • 9,167
1 vote

what happens when a stock price gaps over buy/sell stop order?

It's not a limit order, a stop market is a market order placed on a price trigger. The actual rules for how they are triggered is exchange/broker dependant, so you should seek an answer from the ...
  • 607
1 vote

Order books theoretical price

It is totally up to the type of use or the type of interpretation that you want to give to the theoretical price and also it depends on what are your belief about the information content of the queue ...
  • 11
1 vote
Accepted

Why some exchanges enforce that you send the total quantity (fill qty + open qty) when changing the order size?

Let's say you have an order with 10 shares open. Now you want to cancel it down to 6 shares. If you send just the open quantity you can have the following scenario: Reduce to 6 sent 3 shares got ...
  • 527
1 vote

How can one get broker order data?

When an exchange (or ECN) receives an order, there is no identifier of the buyer or seller. Therefore the only place that this is available is at the broker themselves. No broker would be willing to ...
  • 1,252
1 vote

What is the correct / expected behavior for a market order sent to an empty book?

On BATS, your market order would be rejected back to you with an error "No Liquidity".
  • 141
1 vote

Where do these Orders come from and what do they mean?

If it was on Nyse or NASDAQ, could be a special order type (only if on first limit: some participants can send orders that are activated only to prevent a "trade through", i.e. if there is no other ...
  • 10.7k
1 vote

Data feed that shows individual orders

(I assume you're referring to US equities.) Most normalized, vendor data feeds that you see are sourced from the CTA/UTP SIPs, which don't provide breakdown of individual orders. To see the ...
  • 1,820

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