Topic 3 - Computing portfolio risk and return. After you have mastered the material in this chapter, you will be able to: Compute correlation and covariance matrices, compute the standard deviation of a portfolio of risky assets, use matrix algebra to compute portfolio return and risk, use VBA comments and application object. | Financial Modeling Topic #3: Computing Portfolio Risk and Return L. Gattis 1 2 References Financial Modeling 3rd Edition by Simon Benninga Modeling Support Ch. 8: Portfolio Models Ch. 36: User Defined Functions with VBA Ch. 31: Matrices Learning Objectives Compute correlation and covariance matrices Compute the standard deviation of a portfolio of risky assets Use matrix algebra to compute portfolio return and risk Use VBA comments and application. object 3 Monthly Return Data 4 Copy and save as macro enabled workbook Expected Return for a portfolio with N-assets Expected rate of return of the portfolio: i=1 to N wiri 1 w1r1 2 w2r2 3 w3r3 Sum= w1r1+w2r2+w3r3 ., N=3 5 Calculating Portfolio Return in Excel The sumproduct function computes the sum of the product of two row or column vectors =sumproduct(wts,ret) You could also use matrix multiplication to compute portfolio return 6 7 Matrices (Chapter 27) A matrix is a rectangular array of numbers A matrix with only one row is a row vector A matrix with only one column is a column vector A single letter is often used to denote a matrix (., Matrix A) Aij refers to the value in row i and column j of Matrix A 8 Matrix Multiplication Multiplication of Matrices Matrix A can be multiplied by Matrix B (written AxB or AB), if the number of columns of A equals the number of rows in Matrix B. (inside dimensions (rC*Rc) The resulting matrix has the same number of rows as the first matrix and the number of columns as the second matrix (outside dimensions Rc*rC) If the outer dimensions are 1, the result is a single number Each element of the new matrix AB (ABij) is the sum “sumproducts” of the ith row of A times the jth column of B. (Element ABij=ΣAiBj) Excel uses MMULT(Matrix1,Matrix2) to perform matrix multiplication You must use “Ctrl, Shift, Enter” to enter an array in excel 9 Multiplication To copy formula: highlight area, press f2, press ctrl-shift-enter 9 1. By Hand ABij=sum product of (Ri of A x Cj of B); AB11=sum . | Financial Modeling Topic #3: Computing Portfolio Risk and Return L. Gattis 1 2 References Financial Modeling 3rd Edition by Simon Benninga Modeling Support Ch. 8: Portfolio Models Ch. 36: User Defined Functions with VBA Ch. 31: Matrices Learning Objectives Compute correlation and covariance matrices Compute the standard deviation of a portfolio of risky assets Use matrix algebra to compute portfolio return and risk Use VBA comments and application. object 3 Monthly Return Data 4 Copy and save as macro enabled workbook Expected Return for a portfolio with N-assets Expected rate of return of the portfolio: i=1 to N wiri 1 w1r1 2 w2r2 3 w3r3 Sum= w1r1+w2r2+w3r3 ., N=3 5 Calculating Portfolio Return in Excel The sumproduct function computes the sum of the product of two row or column vectors =sumproduct(wts,ret) You could also use matrix multiplication to compute portfolio return 6 7 Matrices (Chapter 27) A matrix is a rectangular array of numbers A matrix with only one row is a row .