by jrochkind1 · 3y ago · 0 comments
I didn't even know about this process. I don't know much about trading, but it surprises me that there is a separate process for setting prices at the start of trading, and that if it's missed, chaotic prices result.
Is this related to how stock markets aren't really ever open 24 hours? Do they need that reset to function in stable way?
Part of it is legacy from when trading was done by actual humans being at the exchange physically to trade during those times and part of it (I would guess is still the case) is to allow plenty of non-trading hours for back-office jobs and settlement.
So yes there's a special start of day process that runs at 9:30 that runs through all the orders on the books at that time and determines a price at which some optimal set of those orders can trade, trades them at that price, and also posts that price as the Open price for the day.
The process is different during continuous trading since orders are one by one matched against the order book.
Source: ran one of the world's largest equity platforms for 5 years.
The price is usually calculated algorithmically by the DMM firm and sent to the person at NYSE to approve. Pretty arcane. Also somewhat shady, as the DMM firm can be and is part of the auction themselves. DMM firms can analyze the order book to see what the imbalance is in the overlapping region, and place an order of their own to correct the imbalance and then set the opening price. I can see how one can profit from this in certain situations
Now, as a result, there needs to be a way to set the opening price and closing price, like a bootstrap process. A smaller version of this process actually happens every time a stock gets halted and resumed.
An exchange has an order book - orders of things people want to buy and sell at different prices. During normal operation the buy and sell orders don't overlap in the order book - if two people want to buy and sell at the same overlapping price, they just get matched by the exchange at that moment. Unmatched orders stay in the order book data structure until a matching order comes along. The "price" you see in charts is just the midpoint between the highest buy and lowest sell price in the order book.
Now, if the order book is empty, what the heck is the price? That's what the opening auction needs to solve. The way it works is that people can start placing orders ahead of the opening bell, but they won't get matched until the open. So before the open, the order book is getting filled with orders, but crucially the _orders will overlap_. This "crossed" order book is a no no during normal trading, but ok before the opening auction. When the auction comes, a price is picked which maximizes the amount of orders filled (it's more nuanced than that, but bear with me). Imagine you pick a price in the overlapping region of the order book - every buy order that has a higher price than that will match with every sell orders that has a price lower than that. They will get matched and executed at the opening price, and BAM, you have an uncrossed order book, full of orders.
If the auction doesn't happen, and you just open the stock, then all hell breaks loose. Many things can go wrong here. Firms connected to the exchange may have code that assumes a book is not crossed (or at least not as crossed as it would be during an auction) causing wild behavior. The exchange itself could start matching orders haphazardly in the overlapping region, causing those "price swings" that the article talked about.
Can't imagine the panic that day haha.
> Now, as a result, there needs to be a way to set the opening price and closing price, like a bootstrap process. A smaller version of this process actually happens every time a stock gets halted and resumed.
So this suggests that if you did have a hypothetical exchange that ran 24/7... and something unusual happened to make trading halt completely (which always is going to happen occasionally, whether 9/11 level or more frequently)... you would still need to have that "bootstrap" process in place to re-start trading.
But if you normally ran 24/7, you'd have a process that you maybe had never used, or hadn't used in years!
This maybe provides another justification that isn't just historical for having exchanges shut down every day. So you are at least testing the bootstrap process daily, you don't have a bootstrap process you're going to need in an emergency (the worst time to have further problems) that has actually just been sitting around unused for years!
(Reminding me of making sure you test your backup and continuity processes regularly, right? And the irony here is that it's the backup/continuity processes which are alleged to have caused the issue here! but still, you need the backup/continuity processes...)
Does that track with your understanding?
A buy market order would try to match with the "best price" which in a deeply crossed book would mean matching with a really low priced sell order. Exchanges match orders in price-time priority. Similar is true for a market sell order - would match at an extreme high price.
Besides the midpoint of the order book, another metric for a "current price of the stock" people use, is the "last trade price". In the situation above you would get "swings" in the price because market orders would be trading very high and very low if they alternate between buying and selling. The data structure on the exchange itself isn't "swinging", it's just the overlapping region being slowly eroded by market orders. The "last trade price" metric looks really insane in this situation.