I there a graph correlating fee size and confirmation time?
A graph where I can see the fee paid by transactions which got confirmed in less than 20 minutes. Is there a graph like that?
Bitcoin Stack Exchange is a question and answer site for Bitcoin users, developers, and enthusiasts. It only takes a minute to sign up.
Sign up to join this communityI there a graph correlating fee size and confirmation time?
A graph where I can see the fee paid by transactions which got confirmed in less than 20 minutes. Is there a graph like that?
I put together this script that spits out a table of exactly that information directly from your full node:
fees
:
#!/usr/bin/env bash
getprice () {
curl -sL 'https://api.bitfinex.com/v2/tickers?symbols=tBTCUSD' | jq '.[0][1]'
#curl -sL 'https://api.quadrigacx.com/v2/ticker' | jq -r .last
}
n=${1:-100}
size=${2:-226}
price=${3:-$(getprice)}
for x in $(seq 1 $n)
do
bitcoin-cli estimatesmartfee $x
done \
| sed -e 's,\(0.[0-9]\+\),"\1",g' \
| jq -r "[.feerate, .blocks, (((.blocks * 10)/60)*100 | floor)/100, (.feerate | tonumber | ((. * $size)/1000) * $price) ] | @tsv" \
| sort -n -u -t$'\t' -k1,1 \
| tac \
| column -t -s $'\t'
usage:
All arguments are options. jq required.
fees [blocks] [tx size] [price]
outputs:
feerate blocks hours fees (fiat)
0.00128259 2 0.33 1.65150777465
0.00110992 3 0.5 1.4291718392
0.00105930 6 1 1.3639917555
0.00100597 8 1.33 1.29532218095
0.00096015 13 2.16 1.23632274525
0.00091192 14 2.33 1.1742201092
0.00082616 15 2.5 1.0637925316
0.00079090 17 2.83 1.0183905215
0.00056060 20 3.33 0.7218481809999999
0.00005352 25 4.16 0.06891422520000001
0.00005093 61 10.16 0.06557925055000001
then you can
bitcoin-cli settxfee 0.00105930
the satoshis per byte are simply
$ bc <<< '(0.00105930 * 100000000)/1000'
105
For the sake of this question's PageRank, there is now such a service: https://bitcoinfees.21.co/ .
I have made a similar graph here
It shows how much fee transactions pay and how long they are in mempool. (Which is different from what you are asking, but similar.)
It's not very pretty, since I didn't have time to add CSS yet.
Note that it doesn't get CPFP into account at all.