Skip to content

Latest commit

 

History

History
20 lines (16 loc) · 634 Bytes

File metadata and controls

20 lines (16 loc) · 634 Bytes

Simple Order Book Data Structure

Messages (Ticks):

  • NEW: order_id, price, quantity
  • MOD: order_id, mod_price, mod_quantity
  • CXL: order_id
  • TRD: b_order_id, s_order_id, traded_price, traded_quantity

Data structure that publishes K (say 5) depth bid, ask <price, quantity> tuples every time this data structure has an update.

Sample Output


Bid Depth

Price: 100, Quantity: 55
Price: 95, Quantity: 120


Ask Depth

Price: 100, Quantity: 25
Price: 190, Quantity: 50