nbto_optimize: Optimize NBTO

Description Usage Arguments Value

View source: R/Optimization.R

Description

Function to iteratively apply NBTO function to portfolio. Includes runtime and max iteration constraints. Used internally in optimize and meet constraints functions

Usage

1
2
3
4
nbto_optimize(pobj, cobj, eobj, prices, trade_pairs, n_pairs, target,
  minimize, amount, lot_size, max_iter = 5, max_runtime = 60,
  improve_lag = 5, min_improve = 0.001, include_port = TRUE,
  update_trade_pairs = TRUE, random_pairs = TRUE)

Arguments

pobj

portfolio object

cobj

constraints object

eobj

estimates object

prices

data.frame with current symbol prices. Has to contain all symbols included in estimates object. Should also include dividend

trade_pairs

trade pairs to consider. trades limited to the trade pairs provided

target

target objective

minimize

logical flag to minimize target objective

amount

trade amount in dollars

lot_size

lot size for trades

include_port

logical flag to include the portfolio object provided in the canidate list. Default is FALSE.

update_trade_pairs

logical option to update the trade pairs after optimize step. Default is FALSE

random_pairs

logical option to take weighted random sample of trades or top_n

Value

list with list of portfolios, portfolio values, updated trade pairs and runtime


chrishaarstick/madstork.opt documentation built on Nov. 12, 2019, 9:39 p.m.