%% Determine if Array Contains Calendar Duration Values
% Determine if the output of an arithmetic calculation is a calendarDuration array.
% Add two calendarDuration arrays.

d1 = calyears(1:4);
d2 = caldays(1:4);
d = d1 + d2

%
% Determine if the output is a calendarDuration array.

tf = iscalendarduration(d)

% Copyright 2015 The MathWorks, Inc.