Author
Programming Language
Abstract
This package is a set of 12 commands designed to a) collect online financial data, b) optimize portfolios, c) simulate portfolios, and d) backtest portfolios. The 12 commands are the following: 1) returnsyh - gets prices and trade volume of a list of stocks from Yahoo Finance, computes simple and continuously compounded returns, and integrates the data in one dataset 2) meanrets - calculates the expected simple returns of a historical series of continuously compounded returns or simple returns. Expected returns can also be calculated using weights from other variable or using the exponentially weighted moving average (EWMA) method. 3) varrets - calculates the variance-covariance matrix of a series of continuously compounded returns. The variance-covariance matrix can also be estimated using weights from a variable or using the exponentially weighted moving average (EWMA) method. 4) gmvport - calculates the global minimum variance portfolio of a set of continuously compounded returns following Portfolio Theory. 5) mvport - calculates the minimum variance portfolio given a required return following Portfolio Theory. 6) ovport - calculates the optimal variance portfolio that lies in the Capital Market Line. 7) efrontier - generates and graph two efficient frontiers: with and without allowing for short sales. 8) cmline - generates and graph the efficient frontier along with the capital market line when adding a risk-free asset. 9) simport - simulates random portfolios inside the portfolio frontier 10) holdingrets – calculates the holding period return of one or more price variables of a sorted time series dataset 11) backtest - performs a backtest of a financial portfolio. It calculates the holding period return of a specific portfolio 12) cbacktest – performs a cumulative backtest of a financial portfolio. For each time period, a holding return is calculated. It also graphs the cumulative holding period return of the portfolio for all periods. The optimization commands gmvport, ovport, efrontier, and cmline allow for weight constraints such as minimum and/or maximum weights for each asset. They also allow to use any variance-covariance matrix and any vector of expected asset returns. The variance-covariance matrix and the vector of expected returns can be calculated using the EWMA method. In addition, these commands performs risk decomposition for each portfolio asset using Euler’s theorem of decomposition for homogenous functions.
Suggested Citation
Alberto Dorantes, 2013.
"MVPORT: Stata module for Collection, Optimization and Backtest of Financial Portfolios,"
Statistical Software Components
S457712, Boston College Department of Economics, revised 02 Sep 2016.
Handle:
RePEc:boc:bocode:s457712
Note: This module should be installed from within Stata by typing "ssc install mvport". The module is made available under terms of the GPL v3 (https://www.gnu.org/licenses/gpl-3.0.txt). Windows users should not attempt to download these files with a web browser.
Download full text from publisher
Corrections
All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:boc:bocode:s457712. See general information about how to correct material in RePEc.
If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.
We have no bibliographic references for this item. You can help adding them by using this form .
If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.
For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: Christopher F Baum (email available below). General contact details of provider: https://edirc.repec.org/data/debocus.html .
Please note that corrections may take a couple of weeks to filter through
the various RePEc services.