Description
[PortRisk,PortReturn,PortWts] = portopt(ExpReturn,ExpCovariance) sets
up the most basic portfolio problem with weights greater than or equal
to 0 that must sum to 1. All
that is necessary to solve this problem is the mean and covariance
of asset returns. The problem returns 10 equally-spaced points on
the efficient frontier by return.
[PortRisk,PortReturn,PortWts] = portopt(ExpReturn,ExpCovariance,NumPorts) sets
up the basic portfolio problem but lets you specify how many equally-spaced
points on the efficient frontier that you want in NumPorts.
If you specify 1, it returns the minimum-risk
portfolio.
[PortRisk,PortReturn,PortWts] = portopt(ExpReturn,ExpCovariance,NumPorts,PortReturn) sets
up the basic portfolio problem but lets you specify target returns
on the efficient frontier in the vector PortReturn.
This functionality requires that if you set PortReturn, NumPorts should
be empty.
Note
portopt generates a warning if have returns
outside the range and returns the portfolios at the endpoints of the
efficient frontier.
The outputs for portopt are:
PortRisk is an NPORTS-by-1 vector
of the standard deviation of each portfolio.
PortReturn is an NPORTS-by-1 vector
of the expected return of each portfolio.
PortWts is an NPORTS-by-NASSETS matrix
of weights allocated to each asset. Each row represents a portfolio.
The total of all weights in a portfolio is 1.
If portopt is invoked without output arguments,
it writes to the current figure window.