GARCH Toolbox    
price2ret

Convert a price series to a return series

Syntax

Description

[RetSeries,RetIntervals] = price2ret(TickSeries,TickTimes,Method) computes asset returns for NUMOBS price observations of NUMASSETS assets.

Input Arguments



TickSeries
Time series of price data. TickSeries can be a column vector or a matrix:
  • As a vector, TickSeries represents a univariate price series. The length of the vector is the number of observations (NUMOBS). The first element contains the oldest observation, and the last element the most recent.
  • As a matrix, TickSeries represents a NUMOBS-by-number of assets (NUMASSETS) matrix of asset prices. Rows correspond to time indices. The first row contains the oldest observations and the last row the most recent. price2ret assumes that the observations across a given row occur at the same time for all columns, and each column is a price series of an individual asset.

TickTimes
A NUMOBS element vector of monotonically increasing observation times. Times are numeric and taken either as serial date numbers (day units), or as decimal numbers in arbitrary units (e.g., yearly). If TickTimes = [] or is not specified, then price2ret assumes sequential observation times from 1, 2, ..., NUMOBS.
Method
Character string indicating the compounding method to compute asset returns. If Method = 'Continuous', = [], or is not specified, then price2ret computes continuously compounded returns. If Method = 'Periodic', then price2ret assumes simple periodic returns. Method is case insensitive.

Output Arguments



RetSeries
Array of asset returns:
  • When TickSeries is a NUMOBS element column vector, RetSeries is a NUMOBS-1 column vector.
  • When TickSeries is a NUMOBS-by-NUMASSETS matrix, RetSeries is a (NUMOBS-1)-by-NUMASSETS matrix. price2ret quotes the th return of an asset for the period TickTimes(i) to TickTimes(i+1) and normalizes it by the time interval between successive price observations.

Assuming that

then if Method = 'Continuous', = [], or is not specified, price2ret computes the continuously compounded th return of an asset as
If Method = 'Periodic', then price2ret computes the th simple return as

RetIntervals
NUMOBS-1 element vector of interval times between observations. If TickTimes = [] or is not specified, price2ret assumes that all intervals are 1.

Examples

Create a stock price process continuously compounded at 10 percent, then convert the price series to a 10 percent return series.

See Also
ret2price


  parcorr ret2price 

Learn more about the latest releases of MathWorks products:

 © 1994-2009 The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS