Randomized portfolio risks, returns, and weights
[PortRisk, PortReturn, PortWts] = portrand(Asset, Return,
Points, Method)
portrand(Asset, Return, Points, Method)
 Matrix of time series data. Each row is an observation and each column represents a single security.  
 (Optional) Row vector where each column represents the
rate of return for the corresponding security in  
 (Optional) Scalar that specifies how many random points
should be generated. Default =  
 (Optional) A character vector that specifies how to generate random portfolios from the set of portfolios with two possible methods:

[PortRisk, PortReturn, PortWts] = portrand(Asset, Return,
Points, Method)
returns the risks, rates of return, and
weights of random portfolio configurations.






portrand(Asset,
Return, Points, Method)
plots the points representing each
portfolio configuration. It does not return any data to the MATLAB^{®} workspace.
Note: Portfolios are selected at random from a set of portfolios such that portfolio weights are nonnegative and sum to 1. The sample mean and covariance of asset returns are used to compute portfolio returns for each random portfolio. 
Bodie, Kane, and Marcus. Investments. Chapter 7.