Contemporary Portfolio Optimization

Simplify your portfolio optimization process by applying a contemporary modeling way to model and solve your portfolio problems. While most approaches and packages are rather complicated this one tries to simplify things and is agnostic regarding risk measures as well as optimization solvers. Some of the methods implemented are described by Konno and Yamazaki (1991) , Rockafellar and Uryasev (2001) and Markowitz (1952) .


© 2013-2018 Ronald Hochreiter / [email protected]

This package aims at implementing something along the lines of a tidy portfolio optimization framework, simplifying the whole process from data to decision as good as possible.

More about Finance with R can be found at http://finance-r.com/

Main Motivation

The main motivation is to create a R package that simplifies the process of portfolio optimization as much as possible. Furthermore providing an approach to portfolio optimization which is completely agnostic to risk measures and optimization methods. Finally the approach should naturally fit into the contemporary R piping concept using packages like magrittr.

Usage

Instant gratification

# Load the package
library(portfolio.optimization)

# Use any scenario data, e.g. the one provided with the package
data(sp100w17av30s)

# Do a portfolio optimization in one line
weights(optimal.portfolio(scenario.set))

Piping using magrittr

Furthermore, everything should be pipeable and such is the design of the package, i.e.

# The above initial portfolio optimization can be piped as follows 
scenario.set %>% 
  optimal.portfolio %>% 
  weights

# Of course, this is interesting if you change lots of parameters and keeps your
# portfolio models readable and well-shaped for communication
scenario.set %>% 
  portfolio.model %>% 
  objective("expected.shortfall") %>% 
  alpha(0.1) %>% 
  upper.bound(0.2) %>%
  optimal.portfolio %>% 
  weights

Further examples

There are some tutorials built into the package, which you may e.g. open with the following commands:

file.edit(po.tutorial("101"))
file.edit(po.tutorial("compare"))

News

180818

  • Version 1.0-0 submitted to CRAN

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("portfolio.optimization")

1.0-0 by Ronald Hochreiter, 10 months ago


http://www.finance-r.com/


Browse source code at https://github.com/cran/portfolio.optimization


Authors: Ronald Hochreiter [aut, cre]


Documentation:   PDF Manual  


MIT + file LICENSE license


Depends on xts, MASS, magrittr, modopt.matlab


See at CRAN