Charts / React finance charts / Markets
Order book depth
Cumulative bids and asks stepping away from the mid, so you can read the spread, the walls and what a sweep to any price would cost.
React component OrderBookDepth, data through props. Prices, order books, curves and risk: the vocabulary of a trading desk. Tags: order-book, depth, bids-asks, liquidity, crypto, trading, step-area.
Install
npm i klar-charts
import 'klar-charts/styles.css'
import { ThemeScope, OrderBookDepth } from 'klar-charts'
# or copy the source:
npx shadcn@latest add https://klar.run/r/fin-order-book.json
Usage
<OrderBookDepth className="mt-4" bids={book.bids} asks={book.asks} base="ETH" quote="USD" height={380} />
Related order book depth charts
- Candlestick with volume: Daily OHLC candles over a shared-axis volume pane, with moving averages, an optional Bollinger band and a crosshair readout of every…
- Yield curve: The term structure today against a month and a year ago, with inversion against the 3M yield shaded and the 2s10s spread called out.
- Volatility surface: Implied volatility by strike and expiry as a banded contour grid, linked to the smile of any expiry and the at-the-money term structure.
- Equity and drawdown: An equity curve against its benchmark above the underwater curve, with the deepest drawdowns shaded from peak to recovery.
- Correlation matrix: Pairwise correlations of twelve assets, clustered so related markets sit together, with each mark sized by the strength of the link.
- Market treemap: Every stock in an index as a tile sized by market cap and coloured by its daily move, grouped into sectors with their weighted change.