%% Find Accrued Interest for a Bond
% This example shows how to find the accrued interest for given bond data.

Settle = '14-Mar-1997';
Maturity = ['30-Nov-2000'
            '31-Dec-2000'
            '31-Jan-2001'];
Period = 2;
Basis = 0;
EndMonthRule = 1;

Fraction = accrfrac(Settle, Maturity, Period, Basis,... 
EndMonthRule)

% Copyright 2015 The MathWorks, Inc.