nxt.getAccountsStats: Get summary account activity statistics for a set of NXT...

Description Usage Arguments Value Author(s) See Also

Description

This function queries the NXT blockchain and returns summary statistics regarding transactions and forging for a set of NXT accounts for a given time period.

Usage

1
2
3
nxt.getAccountsStats(con, account.ids = NULL, start.ts = NULL,
  end.ts = NULL, ts.from.db = TRUE, id.from.db = TRUE,
  calc.balance = TRUE)

Arguments

con

Connection object to the NXT H2 database.

account.ids

A vector with NXT IDs of accounts to look for. Defaults to calculating statistics for all accounts.

start.ts

Minimum timestamp of transactions and blocks. Can be in seconds since genesis or POSIXct format. Defaults to start of NXT blockchain.

end.ts

Maximum timestamp of transactions and blocks. Can be in seconds since genesis or POSIXct format. Defaults to end of NXT blockchain.

ts.from.db

Boolean. If TRUE (default), convert timestamps to POSIXct, otherwise keep them in seconds since genesis block.

id.from.db

Boolean. If TRUE (default), output block and account IDs in canonical NXT format, otherwise leave in signed long format.

calc.balance

Boolean. If TRUE (default), a balance will be calculated for each account. This balance will only reflect transactions occuring between start.ts and end.ts.

Value

A data.frame with the following columns corresponding to statistics for a given set of account IDs over a given time period:

ACCOUNT_ID

NXT account ID from list given in account.ids

N_REC

Number of times account received NXT

N_MESS_REC

Number of messages received by account

N_MESS_SENDERS

Number of distinct accounts sending messages to this account

NXT_REC

Amount of NXT sent to this account

FIRST_REC

Timestamp of first transaction received by account

LAST_REC

Timestamp of last NXT transfer to this account

N_TRANS

Total number of transactions of all types sent by this account

FEE_PAID

Total fee paid by this count for sending transactions

NXT_SENT

Amount of NXT sent from this account

FIRST_SEND

Timestamp of first time NXT sent from this account

LAST_SEND

Timestamp of last time NXT sent from this account

N_SEND

Number of times NXT sent from this account

N_MESS_SENT

Number of messages sent from this account

N_MESS_RECIPIENTS

Number of distinct message recipients among messages sent from this account

N_ALIAS_ASSIGNS

Number of alias assignment transactions sent by this account. Not necessarily all alias transactions correspond to different NXT aliases

N_COLORED_TRANS

Number of colored coin transactions sent by this account

N_FORGED

Number of blocks forged by this account

NONZERO_N_FORGED

Number of blocks forged by this account with nonzero fee

FEE_FORGED

Amount of NXT forged by this account

FIRST_FORGED

Timestamp of first block forged by this account

LAST_FORGED

Timestamp of last block forged by this account

NONZERO_FIRST_FORGED

Timestamp of first block forged by this account with nonzero fee

NONZERO_LAST_FORGED

Timestamp of last block forged by this account with nonzero fee

FIRST_ACT

Timestamp of first account activity

LAST_ACT

Timestamp of first account activity

TIME_ACT

Difference between FIRST_ACT and LAST_ACT

BALANCE

Balance of account for time period examined (only if calc.balance=TRUE)

Author(s)

David M. Kaplan dmkaplan2000@gmail.com

See Also

nxt.dbConnect, nxt.convert.ts, nxt.convert.id


dmkaplan2000/Rxt documentation built on May 15, 2019, 9:35 a.m.