%% Convert Price Series to Return Series for a fints Object
% Compute the return series from the following price series:

PriceSeries = [100.0000  100.0000 
110.0000  112.0000
115.5000  116.4800
109.7250  122.3040]

%
% Use the following dates:

Dates = {'18-Dec-2000'
'18-Jun-2001'
'17-Sep-2001'
'18-Dec-2001'}

%
% The fints object is:

p = fints(Dates, PriceSeries)

%
% returnFts is computed as:

 tick2ret(p)

% Note that for n dates in the original time series, there are ( n-1) dates returned for returnFts from tick2ret. The formula for the date output dates is described as: RetDate(i) = PriceDate (i+1).
% Copyright 2015 The MathWorks, Inc.