setDefaultConstraints
Set up portfolio constraints with nonnegative weights that sum to 1
Description
sets up portfolio constraints with nonnegative weights that sum to 1 for
obj
= setDefaultConstraints(obj
)Portfolio
, PortfolioCVaR
, or
PortfolioMAD
objects. For details on the respective workflows when using
these different objects, see Portfolio Object Workflow, PortfolioCVaR Object Workflow, and PortfolioMAD Object Workflow.
sets up portfolio constraints with nonnegative weights that sum to 1 with an additional option
for obj
= setDefaultConstraints(obj
,NumAssets
)NumAssets
.
A "default" portfolio set has LowerBound
= 0
and
LowerBudget
= UpperBudget
= 1
such
that a portfolio Port
must satisfy sum(Port) = 1
with
Port >= 0
.
Examples
Input Arguments
Output Arguments
Tips
You can also use dot notation to set up the default portfolio set.
obj = obj.setDefaultConstraints(NumAssets);
This function does not modify any existing constraints in a portfolio object other than the bound and budget constraints. If an
UpperBound
constraint exists, it is cleared and set to[]
.
Version History
Introduced in R2011a
See Also
setBounds
| getBounds
| setBudget
Topics
- Setting Default Constraints for Portfolio Weights Using Portfolio Object
- Setting Default Constraints for Portfolio Weights Using PortfolioCVaR Object
- Setting Default Constraints for Portfolio Weights Using PortfolioMAD Object
- Portfolio Optimization Examples Using Financial Toolbox
- Supported Constraints for Portfolio Optimization Using Portfolio Objects
- Supported Constraints for Portfolio Optimization Using PortfolioCVaR Object
- Supported Constraints for Portfolio Optimization Using PortfolioMAD Object