订单簿深度
代码
阅读文档 →import { DepthChart } from '@tradecanvas/chart'
const depth = new DepthChart(el, {
data: book, // { bids: [{ price, size }], asks: [...] }
midPriceLine: true,
spreadLabel: true,
theme: 'dark',
})
depth.update(nextBook) // on every change of the book● 模拟行情数据,在你的浏览器中生成
不只看最新价,还要看订单簿:深度、基于 GPU 的流动性热力图、点击交易的价格阶梯和成交量分布。
API: DepthChart
