WebCab Portfolio for .NET v5.0 Demo

CapitalMarket.MarketPortfolio Method (Double[][], Double[], Double)

Finds the Market Portfolio by searching over the entire range of the Efficient Frontier.

public double[] MarketPortfolio(
   double[][] covarianceMatrix,
   double[] expectedReturns,
   double marketRate
);

Parameters

covarianceMatrix
The covariance matrix of the assets from which the (optimal) portfolio can be constructed. The dimensions of the (symmetric) covariance matrix will be n X n, where n is the number of assets from which the (optimal) portfolio can be constructed.
expectedReturns
The array of the expected returns of the assets from which the portfolios can be constructed. Where the k-th term will correspond to the percentage return (i.e. 1 percent = 1) or the absolute return of the k-th asset from the set of assets from which the Portfolios (on the Efficient Frontier) can be constructed.
marketRate
The fixed rate at which the investor can borrow or lend money from the market given in decimal format (i.e. 1 percent = 0.01). Recall, that the CAPM assumes that the investor can borrow or lend cash at some prevailing market rate. Though in practice the lending and borrowing costs in general will differ, for large market players such as investment banks these two rates will be approximately the same and be approximately equal to the overnight rate offered between investment banks (i.e. LIBOR or similar). Smaller players can also obtain similar lending and borrow rates through the use of structured products such as REPOs and similar, offered by investments banks. Therefore, for most market participants this assumption is reasonable and does not lead to significant errors. Please note, that this rate refers to the rate the investor will receive on any cash held within the portfolio as well as the rate at which they are able to borrow cash from the market.

Remarks

The weights of the assets of the Market Portfolio are returned as an array where the k-th element of the array corresponds to the weight of the k-th assets within the Market Portfolio.

For more details concerning the issues effecting the constraints, efficiency, number of interpolation points use and so on...; we refer the reader to the documentation for the method MarketPortfolio. As mentioned above the only difference with the aforementioned method at that here the range of the expected returns have been set as detail below.

Range over which the Expected Returns are set

The range over which the expected returns are set and hence the (constrained) Efficient Frontier is evaluated can be evaluated by using the methods MinFrontierReturn, MaxFrontierReturn; in order to evaluate the minimum and maximum of the continuous range of the expected return over which the Efficient Frontier exists for the given set of assets considered. Note that with this procedure we have set the range over which the Efficient Frontier is constructed to be equal to this largest possible range.

Dependency of this Construction

The Market Portfolio is found by searching along the (possibly constrained) Efficient Frontier and therefore before this methods is called and the Market Portfolio sort; the constraints on the assets should be set and the corresponding the Efficient Frontier should be constructed. You are able to set the constraints on the asset weights by calling SetConstraints, and then the (possibly constrained) Efficient Frontier over the entire possible range of values of the expected returns can be constructed by calling the method: CalculateEfficientFrontier. Please note that if the Efficient Frontier most be constructed over the entire possible range of expected returns because the interval over which it is constructed must be at least as big as the interval over which the Market Portfolio is sort which here in the entire range.

See Also

CapitalMarket Class | WebCab.Libraries.Finance.Portfolio Namespace | CapitalMarket.MarketPortfolio Overload List | MarketPortfolio | MinFrontierReturn | MaxFrontierReturn