Retrieves historical values of the blockhain statistics

get_chain_statistics(
  days = 14,
  include_current_date = FALSE,
  max_attempts = 3L
)

Arguments

days

(double): number of days to look back (defaults to 14 days).

include_current_date

(boolean): whether the current date's statistics (as of the query time) should be returned. Defaults to FALSE.

max_attempts

(integer, positive): specifies the maximum number of additional attempts to call a URL if the first attempt fails (i.e. its call status is different from 200). Additional attempts are implemented with an exponential backoff. Defaults to 3.

Value

A tibble with the following columns:

  • date (Date): date in the YYYY-MM-DD format;

  • avg_block_size (double): average block size (in bytes);

  • total_blocks (integer): cumulative number of blocks on the chain;

  • new_blocks (integer): number of newly generated blocks;

  • chain_size (double): cumulative size of the chain (in bytes);

  • total_addresses (integer): cumuative number of address on the chain;

  • active_addresses (integer): number of addresses that were active on date;

  • new_addresses (integer): number of newly created addresses;

  • addresses_with_trx (integer): number of Tronix (TRX)-holding addresses;

  • total_trc10_tokens (integer): cumulative number of TRC-10 assets on the chain;

  • total_trc20_tokens (integer): cumulative number of TRC-20 assets on the chain;

  • new_trc10_tokens(integer): number of newly created TRC-10 assets;

  • new_trc20_tokens (integer): number of newly created TRC-20 assets;

  • new_tx (integer): number of new transactions on the chain;

  • trx_transfer_tx (integer): number of TRX transfer transactions;

  • trc10_transfer_tx (integer): number of TRC-10 transfer transactions;

  • freeze_tx (integer): number of TRX freezing transactions;

  • vote_tx (integer): number of vote transactions;

  • other_tx (integer): number of other transactions;

  • contract_triggers (integer): cumulative number of smart contract triggers;

  • energy_usage (double): amount of energy consumed;

  • net_usage (double): amount of bandwidth consumed.

Examples

r <- get_chain_statistics(days = 7) print(r)
#> # A tibble: 7 x 22 #> date avg_block_size total_blocks new_blocks chain_size total_addresses #> <date> <dbl> <int> <int> <dbl> <int> #> 1 2021-07-05 94159 31685778 28755 632248660814 43601994 #> 2 2021-07-06 105097 31714463 28685 635263395750 43863554 #> 3 2021-07-07 88883 31743138 28675 637812117450 44061890 #> 4 2021-07-08 73906 31771827 28689 639932424139 44253663 #> 5 2021-07-09 60405 31800595 28768 641670157765 44442413 #> 6 2021-07-10 56582 31829370 28775 643298307555 44579395 #> 7 2021-07-11 58084 31858144 28774 644969641036 44726023 #> # … with 16 more variables: active_addresses <int>, new_addresses <int>, #> # addresses_with_trx <int>, total_trc10_tokens <int>, #> # total_trc20_tokens <int>, new_trc10_tokens <int>, new_trc20_tokens <int>, #> # new_tx <int>, trx_transfer_tx <int>, trc10_transfer_tx <int>, #> # freeze_tx <int>, vote_tx <int>, other_tx <int>, contract_triggers <int>, #> # energy_usage <dbl>, net_usage <dbl>