Sunteți pe pagina 1din 55

An introduction to portfolio optimisation

Susan Thomas IGIDR, Bombay

October 21, 2011

Susan Thomas

An introduction to portfolio optimisation

Goals

What is a portfolio? Asset classes that dene an Indian portfolio, and their markets. Inputs to portfolio optimisation: measuring returns and risk of a portfolio Optimisation framework: optimising a risky portfolio using the Markowitz framework Outcome 1: passive portfolio management Outcome 2: active portfolio management Evaluating portfolio performance

Susan Thomas

An introduction to portfolio optimisation

A portfolio

Investments in a set of assets together make a portfolio. As opposed to an investment in a single asset. A portfolio is dened as:
The value of the investment (portfolio). Assets held in the portfolio. Fraction of the value invested in each asset. These are called the weights of each asset in the portfolio, and are typically denoted as wi for asset i .

Choosing a portfolio is equivalent to choosing the weights of assets in a portfolio.


1 2

How are these weights chosen? Would the same weights serve the best interests of all investors?

Susan Thomas

An introduction to portfolio optimisation

Portfolio choice centers on risk vs. return

Every portfolio outcome is nally measured by the amount of return it gave for a certain amount of risk taken. Therefore, portfolio choice follows two stages:
1

capital allocation: how much of riskless vs. risky assets to hold? security section:
What underlying assets constitute a riskless portfolio? What constitutes a risky portfolio?

Susan Thomas

An introduction to portfolio optimisation

What assets can we access?

Riskless Risky

Leverage/Risk management

Govt. bonds Corporate bonds, rm equity, commodities, foreign exchange, foreign equity, foreign government bonds Derivatives

Susan Thomas

An introduction to portfolio optimisation

Measurement of risk and return

Susan Thomas

An introduction to portfolio optimisation

Why emphasise the measurement?

Portfolio optimisation depends upon the tradeoff between the future risk and expected return of the portfolio. The higher the future risk, the higher the expected return demanded by a risk-averse investor. Thus, future risk and expected return have to be modelled and forecasted as inputs into portfolio choice.. Problem: key inputs are observed (past) returns vs. risk behaviour for the portfolio. These pose severe challenges.

Susan Thomas

An introduction to portfolio optimisation

Challenges in measuring return and risk

Past returns are easy to measure when assets are traded and prices are observed. Challenge: There is no consensus on good forecasting models for expected returns. Challenge: how to measure risk? Unlike the dynamics of prices, which we measure as returns, there is no separate instrument to observe risk? Once they are measured (typically by proxy), there appear to be reasonably good forecasting models for risk.

Susan Thomas

An introduction to portfolio optimisation

How do we measure volatility?

Volatility is 2 of returns, or the standard deviation of returns instead, . The dependent variable used in the modelling and forecasting exercise is . However, this is static measure of volatility. Real world observation: variance changes. We need a time series of volatility.

Susan Thomas

An introduction to portfolio optimisation

Approaches to create time series of volatility

Traditional approaches:
1 2 3

Time series of rt2 , Moving window average , Range of prices as a measure of .

Recent approaches using new markets and improved market information:


1 2

Implied volatility from options markets, Realised volatility using high-frequency data.

Susan Thomas

An introduction to portfolio optimisation

Traditional approach: Squared returns

Given a time series of returns at a certain frequency (daily, weekly, monthly, etc), rft . Time series of volatility at the same frequency, ft was created as square of the returns.
2 2 ft = rft

Susan Thomas

An introduction to portfolio optimisation

Traditional approach: rolling windows


Moving window average: Out of a total of T observations on returns, use k < T observations to calculate one value of t . Then, the volatility time series will be:
2 1

1 (k 1)

(ri r )2
i =1 k +1

1 (k 1) ... ... ...


2 2

(ri r )2
i =2 T

2 T k

1 (k 1)

(ri r )2
i =T k +1

Using overlapping windows, we can calculate a time series with T k volatility observations, from T observations for returns data.
Susan Thomas An introduction to portfolio optimisation

Traditional approach: Range


Range is calculated as the difference between the high and the low prices over a given period it tells us how variable prices have been during some period. One way of calculating the volatility of returns using the range Ranget = 100 (Hight Lowt )/Lowt Range is a measure that also uses multiple observations at a given frequency. If we have T points of observation of high and low prices, then we get T observations for the time series of volatility. Formal denition of a range-based volatility measure is 0.361 (100 (log High log Low))2 (Source: Michael Parkinson, 1980. The extreme value method for estimating the variance of the rate of return, Journal of Business, 53 (January):61-65.)
Susan Thomas An introduction to portfolio optimisation

Recent measures of volatility: implied volatility


Implied volatility: Apply an option pricing model to an existing market price for an option to reverse calculate the volatility of the asset. What we need:
1 2

Option price: from the market, daily Pricing model: Black-Scholes, Binomial lattice, etc.

What we get: a daily time series of volatility. What is remarkable: IV is an average of the expected volatility. It is already a forecast of the asset volatility. Issues: If IV measures the volatility of the asset, then all option prices on the same asset should give the same volatility. This is not so: IV changes with strike (volatility smile); with type of option (put/call).
Susan Thomas An introduction to portfolio optimisation

Recent measures of volatility: Realised volatility

Realised volatility (RV): calculated using high-frequency returns. In order to be useful, RV requires that:
The returns data is synchronised (say returns data at every 5-minutes, or at every half-hour). For example, 66 5-minute returns can be used to calculate 5-minute 5min . This can be used to calculate daily as: daily = 665 minutes 11 half hour returns can be used to calculate 0.5hours . This can be used to calcalate daily as: daily = 1130 minutes

Susan Thomas

An introduction to portfolio optimisation

Setup for the portfolio problem: denitions, concepts

Susan Thomas

An introduction to portfolio optimisation

The problem of portfolio optimisation

We are given a (competitive, liquid) market where n assets are traded. The market is efcient - there are no easy forecasts for tomorrows returns. Given an individuals utility function, how does she allocate her wealth among these n assets?

Susan Thomas

An introduction to portfolio optimisation

Rules of the game

ra,t can follow any distribution. Typical model choice 1: Suppose ra,t N (). In a gaussian world, returns on one asset is a random variable x needs:
2 x , x

For returns on two assets, (x , y ), additional requirement: xy or xy

Susan Thomas

An introduction to portfolio optimisation

Interest rates vs. asset rates of return

Risk-free interest rate is rf . rf is assumed to be known upfront and xed. ra is the return obtained in investing in an asset. It is a sum of capital gains and cashow/dividend payouts. ra is a random variable when the investment is done.

Susan Thomas

An introduction to portfolio optimisation

Example: E (rp ), p calculation

Suppose there are two assets: Asset 1: E (r1 ) = 0.12%, 1 = 0.20%. Asset 2: E (r2 ) = 0.15%, 2 = 0.18%. 1,2 = 0.01. Portfolio weights = 0.25, 0.75 What is E (rp ), p ?

Susan Thomas

An introduction to portfolio optimisation

Example of E (rp ), p calculation


Expected returns is a weighted average of individual returns. E (rp ) = w E (ra ) = (0.25 0.12) + (0.75 0.15) = 0.1425
2 is a little more complicated: Variance of the portfolio is w 2 p = w w

= (0.252 0.202 ) + (0.752 0.182 ) + 2 (0.25 0.75 0.01 = 0.024475 p =


2 = 0.15644 p

Here, we also require the correlation between the two assets, 1,2 = 0.01.
Susan Thomas An introduction to portfolio optimisation

Example 2: E (rp ), p calculation for a 3-asset portfolio

Suppose we add one more asset to our set of 2: Asset 1: E (r1 ) = 0.12%, 1 = 0.20%. Asset 2: E (r2 ) = 0.15%, 2 = 0.18%. Asset 3: E (r2 ) = 0.10%, 3 = 0.15%. 1,2 = 0.01, 1,3 = 0.005, 2,3 = 0.008 Portfolio weights = 0.25, 0.25, 0.5 What is E (rp ), p ?

Susan Thomas

An introduction to portfolio optimisation

Example: E (rp ), p calculation


We calculate it using the same equations as before:

E (rp ) = w E (ra ) = (0.25 0.12) + (0.25 0.15) + (0.5 0.10) = 0.1175


2 p = w w

= (0.252 0.202 ) + (0.252 0.182 ) + (0.52 0.152 ) + 2 (0.25 0.25 0.01) + 2 (0.25 0.5 0.005) + 2 (0.25 0.5 0.008) = 0.015 p =
2 = 0.12 p

Susan Thomas

An introduction to portfolio optimisation

E (rp ), p for different w


= 0.25, 0.5, 0.25 we have For an alternative portfolio, w E (rp , p ) as: E (rp ) = w E (ra ) = (0.25 0.12) + (0.5 0.15) + (0.25 0.10) = 0.13
2 p = w w

= (0.252 0.202 ) + (0.52 0.182 ) + (0.252 0.152 ) + 2 (0.25 0.5 0.01) + 2 (0.25 0.25 0.005) + 2 (0.25 0.5 0.008) = 0.017 p =
2 = 0.13 p

For this portfolio, we have got both higher returns and higher risk.
Susan Thomas An introduction to portfolio optimisation

Observations

Multivariate rather than univariate distributions We need more than an understanding of returns on a single asset: we need to understand their relationship with all the other assets in the portfolio. Diversication The variance on the portfolio is much lower than the variance on either asset. 0.15644 < 0.20 0.15644 < 0.18

Susan Thomas

An introduction to portfolio optimisation

Issues in diversication

Diversication is the reduction in variance of the portfolio returns. This is achieved by:
1

Holding a large number of assets, such that the weights on each become smaller and smaller. Then, the effect of asset i in the portfolio variance is wi2 . The smaller the wi2 , the larger the reduction in variance. Holding uncorrelated assets, ie, create a portfolio with assets (i , j ) such that i ,j is very small. The lower the i ,j across the n assets, the higher the reduction in variance of the portfolio

Susan Thomas

An introduction to portfolio optimisation

Matrix notation in portfolio optimisation


There are k assets, where each looks like it comes from a normal distribution. Jointly, the returns on all these K assets can be written as a vector: ra MVN(, ) is K 1 is K K and is a positive denite symmetric matrix. If portfolio invests in n assets with a set of weights w , the portfolio is then a linear combination of the n assets. Then, the portfolio features are calculated as: rp N (w , w w )

Susan Thomas

An introduction to portfolio optimisation

Summary: portfolio characteristics and portfolio choice

Expected return on the portfolio: E (rp ) = Variance of the portfolio: n n 2 = 2 2 p i =1 wi i + 2 i =1


n j =1 wi wj ij

n i =1 wi E (ri ).

Susan Thomas

An introduction to portfolio optimisation

Values of w

w sums to one. Typically, we consider each wi to fall between 0 and 1. In a country where short-selling is permitted, wi can be less than 1, or greater than 1. Choosing the portfolio means choosing a vector of weights w. Once w is chosen, we know the E (rp ) and p for the portfolio.

Susan Thomas

An introduction to portfolio optimisation

The E (rp ) p graph

2. Every choice w induces two numbers - E (rp ) and p

A key analytic tool to choose w : E (ra ) a graph. A graph with E (rp ) on the yaxis and on the xaxis. For all possible portfolios containing the same assets, but in different proportion, plot the portfolio as a point on the E (r ) graph. This is a simple 2-D graph, regardless of how many assets you have!

Susan Thomas

An introduction to portfolio optimisation

Varying w from 0 to 1 in a E (rp ) p graph

Susan Thomas

An introduction to portfolio optimisation

Optimisation
Now we are ready to understand the problem space of portfolio optimisation. Start with a two-asset universe: With two assets, (A, B ) where (A, B MVN(, ) is 2 1 with A , B . 2 , 2 , . and is 2 2 with A B AB The investment in one asset as w . Then, the investment in the other is 1 w . Porfolio optimisation problem: for the parameters in , , nd the optimal w .

Susan Thomas

An introduction to portfolio optimisation

Varying w from 0 to 1 - interpretation

The previous graph shows how E (rp ) p combination changes as w changes. There is some value of w for which E (rp ) is the maximum. There is some value of w for which p is the minimum. w for maximum E (rp ) and minimum p is not the same.

Susan Thomas

An introduction to portfolio optimisation

What happens if changes?

E(r)

A
sigma

Susan Thomas

An introduction to portfolio optimisation

Changing - interpretation

How does the E (rp ), p graph vary with changing values of ? AB is (E (rp ), p ) for all nonnegative linear combinations of A and B, when AB = 1. PA and PB dene the boundaries of (E (rp ), p ) (1 < AB < 1). The curve AB denes (E (rp ), p ) for all nonnegative linear combinations of A and B for some intermediate xed value of AB .

Susan Thomas

An introduction to portfolio optimisation

Choosing the correct portfolio

Given this graph,


1 2

We rst choose a desired E (rp ). We next choose w such that the variance is minimised for a selected value of E (rp ). This is the optimal portfolio with (1 w ) in asset A and w in asset B.

Susan Thomas

An introduction to portfolio optimisation

Special case of capital allocation

Susan Thomas

An introduction to portfolio optimisation

Capital allocation between risky and risk-free


We earlier considered any two assets A and B . What if A is the risk-free asset? Then, E (rp ) = wrf + (1 w )E (rB ) This is a linear combination of expected returns as usual. But, 2 ) = w 2 2 + (1 w )2 2 + 2w (1 w )cov (p rf ,B , where we rf B know:
rf = 0 covrf ,B = 0

Then,
2 ) = (1 w )2 2 , or (p B

p = (1 w )B

Susan Thomas

An introduction to portfolio optimisation

Interpreting the E (rp ) p graph for risky and risk-free

Remarkable result: A portfolio of the risk-free and one risky asset has an E (rp ) p graph which is linear in both E (rp ) and . This means that as you increase w , p decreases linearly. For example, at w = 1, p = 0 At w = 0, p is the maximum. Solution to the capital allocation problem: risk-return across risky and risk-free assets is linear in w .

Susan Thomas

An introduction to portfolio optimisation

Leverage

Susan Thomas

An introduction to portfolio optimisation

Leverage in w

In the above example, p is bounded to be equal to B because w falls between 0 and 1. By implication, the investor cannot access risk (or returns) that are higher than B . This can change if we have short-selling. Short-selling means w can be negative. If w is negative, it means you borrow at the risk-free rate to invest in the risky security, B . This is leverage. With leverage, you can create portfolios with p > B .

Susan Thomas

An introduction to portfolio optimisation

Example of leverage

An investor has Rs.1 million to allocate between the risk-free asset and risky asset B . The data shows that rf = 7%, rB = 35%, B = 40% What combinations of E (rp ) p can she achieve? At w = 0.5, the portfolio is the riskless asset: E (rp ) = 0.5 7 + 0.5 35 = 21%; p = 0.5 40 = 20%; At w = 1, the portfolio is purely risky asset, B . E (rp ) = 35%; p = 40%

Susan Thomas

An introduction to portfolio optimisation

With leverage

At w = 0.5, the portfolio has:


E (rp ) = 0.5 7 + 1.5 35 = 49% p = 1.5 40 = 60%

How is this achieved? At w = 0.5, the investor borrows half a million from the bank to invest in B . This is a leveraged portfolio: the size of the investment is more than the size of the initial wealth. Note: The risk in the last portfolio is the highest, but the return is also (linearly) high.

Susan Thomas

An introduction to portfolio optimisation

The capital allocation problem redux

The capital allocation problem remains linear: Higher the investment in the risky portfolio, return and risk are linearly higher. The level of return desired drives the quantum of investment in risky vs. riskless asset. Next question: out of all possible combinations of risky assets, what is the optimal risky portfolio?

Susan Thomas

An introduction to portfolio optimisation

Constructing the optimal risky portfolio

Susan Thomas

An introduction to portfolio optimisation

Step2: Optimising the risky portfolio

Next question: among all the risky assets, what is the optimal risky portfolio? We know that the return-risk trade-off among only risky assets is not linear: some combinations of assets give a lower return for a higher level of risk. What does this combination of risk-return look like? We nd out using a simulation with real data.

Susan Thomas

An introduction to portfolio optimisation

Simulating the E (rp ) p graph for a set of 7-stocks

Susan Thomas

An introduction to portfolio optimisation

Example: A dataset of weekly stock returns

load(file="10.rda") colMeans(r) print(cov(r), digits=3)

Susan Thomas

An introduction to portfolio optimisation

Example: Mean-variance of weekly returns

> colMeans(r) RIL Infosys 0.31392 0.15702

TataChem 0.40761

TELCO 0.29796

TISCO TTEA 0.44311 0.12302

Grasim 0.32051

> print(cov(r), digits=3) RIL Infosys TataChem TELCO TISCO TTEA Grasim 29.08 11.01 9.2 12.85 15.93 11.27 8.13 11.01 61.23 10.1 4.06 8.72 7.48 7.60 9.19 10.11 33.9 15.75 14.51 13.75 12.25 12.85 4.06 15.7 38.17 20.16 16.60 7.64 15.93 8.72 14.5 20.16 32.94 13.95 11.79 11.27 7.48 13.8 16.60 13.95 29.64 8.02 8.13 7.60 12.2 7.64 11.79 8.02 34.17

RIL Infosys TataChem TELCO TISCO TTEA Grasim

Susan Thomas

An introduction to portfolio optimisation

Example: Correlations of weekly returns

> print(cor(r), digits=3) RIL Infosys TataChem TELCO TISCO TTEA Grasim 1.000 0.261 0.293 0.386 0.515 0.384 0.258 0.261 1.000 0.222 0.084 0.194 0.176 0.166 0.293 0.222 1.000 0.438 0.434 0.434 0.360 0.386 0.084 0.438 1.000 0.569 0.493 0.212 0.515 0.194 0.434 0.569 1.000 0.446 0.351 0.384 0.176 0.434 0.493 0.446 1.000 0.252 0.258 0.166 0.360 0.212 0.351 0.252 1.000

RIL Infosys TataChem TELCO TISCO TTEA Grasim

Susan Thomas

An introduction to portfolio optimisation

Example: Creating portfolios randomly


load(file="10.rda") mu = colMeans(r) bigsig = cov(r) m = nrow(bigsig)-1 N = 20 w = diff(c(0,sort(runif(m)), 1)); rb = sum(w*mu); sb = sum(w*bigsig*w); for w r s } (j in 2:N) { = diff(c(0,sort(runif(m)), 1)); = sum(w*mu); rb = rbind(rb,r); = sum(w*bigsig*w); sb = rbind(sb,s);

d = data.frame(rb, sb); d$sb = sqrt(d$sb); pdf("10_2.pdf", width=5.6, height=2.8, bg="cadetblue1", pointsi plot(d$sb, d$rb, ylab="E(r)", xlab="Sigma", col="blue")
Susan Thomas An introduction to portfolio optimisation

Example: E(r)- graph, N=20 portfolios

0.4

0.5

0.3

q q

q q q q q q qq q q q qq q q q q

E(r)

0.1

0.2

4 Sigma

10

Susan Thomas

An introduction to portfolio optimisation

Example: E(r)- graph, N=2000 portfolios

0.5

0.4

q q qq q qq q q q q q q q q q qq q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q qqq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qqq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q qq q qq q qq qq q q q q q q q q q q qqq q q q q q q q qq q q q q qq q q

E(r)

0.1

0.2

0.3

4 Sigma

10

Susan Thomas

An introduction to portfolio optimisation

Observations from the simulations

The characteristics of random portfolios (where the weights on the securities are randomly selected) show a convex curve for different w . There is a minimum value of p : no matter what combination of w , there is no way of reaching a lower p with this set of assets. There are a set of portfolios which no-one would want to hold: where E (rp ) decreases as p increases. We need to focus on those portfolios where E (rp ) increases as p increases.

Susan Thomas

An introduction to portfolio optimisation

The Markowitz optimisation

We observe that the return-risk trade-off among only risky assets is not linear: some combinations of assets give a lower return for a higher level of risk. Is there a closed form solution to what is the optimal risky portfolio? Solution: the Markowitz framework.

Susan Thomas

An introduction to portfolio optimisation

S-ar putea să vă placă și