0
$\begingroup$

I need to use the mvnrnd function in matlab to generate random monthly returns for a set of assets. However, I am a bit confused about how to use this function to do it since it asks me MU and SIGMA values. How should I pick these values ?

  • 0
    A$f$ter I get the random values and average them I use portopt to find optimal weights for a range of expected returns. When using portopt, if I specify the expected returns I want in a vector using rMin + i * ( (rMax - rMin) / 9 ) where i<=0<=9, from time to time I get something like: "One or more requested returns are less than the return -0.003414 of the least risky portfolio." However, if dont specify anything there is no error. I thought its because of the negative returns from mvnrnd but then couldn't really figure out why..2012-02-22

1 Answers 1

1

MU and SIGMA are usually estimated from historical data. For example, you can take time series of returns on your asset and compute their sample means (which will be stacked in your MU vector) and their sample covariance matrix (your SIGMA matrix). If the returns to K assets observed over T periods are stored in a KxT matrix R, then the MATLAB commands are:

MU=mean(R)

SIGMA=var(R)

  • 0
    Well, yes. If a security has declined in price over the period you're looking at, you would expect to see negative values for $\mu$. Why is this a problem when finding optimal portfolios?2012-02-22