ACB | R Documentation |
Calculate realized and unrealized capital gains/losses
ACB( data, transaction = "transaction", price = "price", quantity = "quantity", fees = "fees", total.price = "total.price", spot.rate = "spot.rate", as.revenue = c("staking", "interests", "mining"), sup.loss = TRUE, cl = NULL, verbose = TRUE )
data |
The dataframe |
transaction |
Name of transaction column |
price |
Name of price column |
quantity |
Name of quantity column |
fees |
Name of fees column |
total.price |
Name of total.price column |
spot.rate |
Name of spot.rate column |
as.revenue |
Name of as.revenue column |
sup.loss |
Logical, whether to calculate superficial losses |
cl |
Number of cores to use for parallel processing. |
verbose |
Logical: if |
A data frame, with the following columns: date, transaction, quantity, price, fees, total.price, total.quantity, ACB, ACB.share, gains
data <- data_adjustedcostbase1 ACB(data, spot.rate = "price", sup.loss = FALSE) ACB(data, spot.rate = "price")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.