%% Specify a Four-Period Tree with Annual Nodes
% This example shows how to specify a four-period tree with annual nodes using annual compounding to report rates.

ValuationDate = 'Jan-1-2004';
Maturity = ['12-31-2004'; '12-31-2005'; '12-31-2006'; 
'12-31-2007'];
Compounding = 1;
TimeSpec = bktimespec(ValuationDate, Maturity, Compounding)

% Copyright 2015 The MathWorks, Inc.