exchange_calendars
exchange_calendars copied to clipboard
XASX closing auction print
Normal trading ceases at 1600 for the ASX, after which there is a dutch auction at 1610 for the final day-close print. Would it be possible to account for this somehow. Perhaps a 'match' session?
Cheers
Hi @j7zAhU.
exchange_calendars
has historically only been concerned with regular trading times. Although, that's not to say that it couldn't incorporate additional timings. I suspect we'd be open to a PR suggesting a framework to register / provide such information (@gerrymanoim - ?).
I believe pandas_market_calendars now provides for something along these lines - perhaps start by having a look at how it's been implemented there?
Cheers
I've implemented a solution to this, but in another code so cannot comment on feasibility of modifying trading_index()
. But happy to discuss the framework.
I add an "auction" datetime column to calendar, that's only change to schedule. Most work is in creating the trading intervals:
- assume auction consumes 1 minute. Nothing official on end time to confirm this, maybe it's 1 second
- map auction time to a trading interval as if it was during the session, then adjust the 'auction interval' close to match auction end time. If 'auction interval' overlaps the actual last session interval, merge them.
Merging should only happen with large periods e.g. 1h. With small periods e.g. 5m there should be a gap between close and auction.
The final print happens at a random time within that minute