extractTxns: Extract transactions from a portfolio

Description Usage Arguments Details Value Author(s)

Description

This function reverse-engineers addTxn calls for all the transactions in Portfolio. This is the fundamental task required to create a reproducible example, as it would replicate the state of the $txn slot in the portfolio after each addTxn call.

Usage

1
extractTxns(Portfolio)

Arguments

Portfolio

string identifying the portfolio to extract from

Details

While market data, expected results, portfolio and account setup, etc, are also required, these can usually be deduced or equivalent formulations can be found.

For transactions, only the exact addTxn parameters will recreate the $txn slot. This function creates that reproducibility, since the result (stored in 'x') can be used to regenerate transactions with eval(parse(text=x)).

Value

String vector of addTxn calls that would replicate the given portfolio.

Author(s)

Brian G. Peterson, Josh Ulrich



Search within the blotter package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.