【发布时间】:2021-02-27 14:37:51
【问题描述】:
我最近开始调用 Binance API,具体如下: https://api.binance.com/api/v3/ticker/24hr?symbol=BTCBUSD
这个调用似乎只有 1 个参数(符号)。我的问题涉及返回字段的含义,或者如何解释它们。
以下是上述调用返回的数据示例。
{
"symbol": "BTCBUSD",
"priceChange": "1519.63000000",
"priceChangePercent": "3.308",
"weightedAvgPrice": "47059.10006256",
"prevClosePrice": "45935.14000000",
"lastPrice": "47454.77000000",
"lastQty": "0.08014400",
"bidPrice": "47454.76000000",
"bidQty": "0.00858100",
"askPrice": "47454.77000000",
"askQty": "0.22488900",
"openPrice": "45935.14000000",
"highPrice": "48444.00000000",
"lowPrice": "45044.05000000",
"volume": "18094.48897600",
"quoteVolume": "851510367.30253731",
"openTime": 1614347997320,
"closeTime": 1614434397320,
"firstId": 116330237,
"lastId": 117165845,
"count": 835609
}
openPrice 和 prevClosePrice 究竟是什么意思?它们在每次调用之间变化。
priceChange 和 priceChangePercent 是如何工作的?这些值是从哪些字段计算而来的?为什么它们与我在拨打电话的同时查看币安网站的 BTC/BUSD 24 小时期间所看到的明显不同?
谁能解释一下这些数字?我在网上搜索过,但找不到任何描述性的内容。
当我根据 lastPrice 和 openPrice 之间的差异计算价格变化百分比时,我得到以下与 priceChangePercent 值匹配的结果.
((47454.77 - 45935.14) / 45935.14) * 100 = 3.308
【问题讨论】: