You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Merge #13918: rpc: Replace median fee rate with feerate percentiles in getblockstats
4b7091a Replace median fee rate with feerate percentiles (Marcin Jachymiak)
Pull request description:
Currently, the `medianfeerate` statistic is calculated from the feerate of the middle transaction of a list of transactions sorted by feerate.
This PR instead uses the value of the 50th percentile weight unit in the block, and also calculates the feerate at the 10th, 25th, 75th, and 90th percentiles. This more accurately corresponds with what is generally meant by median feerate.
Tree-SHA512: 59255e243df90d7afbe69839408c58c9723884b8ab82c66dc24a769e89c6d539db1905374a3f025ff28272fb25a0b90e92d8101103e39a6d9c0d60423a596714
"\"avgfeerate\": xxxxx, (numeric) Average feerate (in satoshis per virtual byte)\n"
1674
1703
"\"avgtxsize\": xxxxx, (numeric) Average transaction size\n"
1675
1704
"\"blockhash\": xxxxx, (string) The block hash (to check for potential reorgs)\n"
1705
+
"\"feerate_percentiles\": [ (array of numeric) Feerates at the 10th, 25th, 50th, 75th, and 90th percentile weight unit (in satoshis per virtual byte)\n"
1706
+
"\"10th_percentile_feerate\", (numeric) The 10th percentile feerate\n"
1707
+
"\"25th_percentile_feerate\", (numeric) The 25th percentile feerate\n"
1708
+
"\"50th_percentile_feerate\", (numeric) The 50th percentile feerate\n"
1709
+
"\"75th_percentile_feerate\", (numeric) The 75th percentile feerate\n"
1710
+
"\"90th_percentile_feerate\", (numeric) The 90th percentile feerate\n"
1711
+
" ],\n"
1676
1712
"\"height\": xxxxx, (numeric) The height of the block\n"
1677
1713
"\"ins\": xxxxx, (numeric) The number of inputs (excluding coinbase)\n"
1678
1714
"\"maxfee\": xxxxx, (numeric) Maximum fee in the block\n"
1679
1715
"\"maxfeerate\": xxxxx, (numeric) Maximum feerate (in satoshis per virtual byte)\n"
1680
1716
"\"maxtxsize\": xxxxx, (numeric) Maximum transaction size\n"
1681
1717
"\"medianfee\": xxxxx, (numeric) Truncated median fee in the block\n"
1682
-
"\"medianfeerate\": xxxxx, (numeric) Truncated median feerate (in satoshis per virtual byte)\n"
1683
1718
"\"mediantime\": xxxxx, (numeric) The block median time past\n"
1684
1719
"\"mediantxsize\": xxxxx, (numeric) Truncated median transaction size\n"
1685
1720
"\"minfee\": xxxxx, (numeric) Minimum fee in the block\n"
0 commit comments