%% Set Bound Constraints for a PortfolioMAD Object
% Suppose you have a balanced fund with stocks that can range from 50% to 75% of your portfolio and bonds that can range from 25% to 50% of your portfolio. To set the bound constraints for a balanced fund.

lb = [ 0.5; 0.25 ];
ub = [ 0.75; 0.5 ];

p = PortfolioMAD;
p = setBounds(p, lb, ub);
disp(p.NumAssets);
disp(p.LowerBound);
disp(p.UpperBound);

% Copyright 2015 The MathWorks, Inc.