3.mu=matrix(c(.15,.26),nrow=2,ncol=1)
4.mue=mu-rf
5.sigma=matrix(c(.24,.37),nrow=2,ncol = 1)
6.corr=.8
7.cov=corrsigma[1,1]sigma[2,1]
8.mup=.18
9.varcov=matrix(c((sigma[1,1])^2,cov,cov,(sigma[2,1])^2),nrow=2,ncol=2,byr
ow=TRUE)
10.lambda=(mup-rf)/(t(mue)%%solve(varcov)%%mue)
11.omega=lambda[1,1]solve(varcov)%%mue
12.omega3=1-omega[1,]-omega[2]
13.retp=t(mue)%*%omega
14.sigmap=sqrt(t(omega)%%varcov%%omega)}