

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A programming project focused on setting up and solving a linear programming problem related to investment portfolio allocation. The project involves using historical data to estimate expected returns and risks for various investments, and then finding a portfolio with an optimal balance of risk and reward. The problem is formulated as a linear program, and solutions are obtained using matlab. Students are encouraged to read the relevant section in their textbook and use the provided matlab scripts to load data and solve the problem.
Typology: Study Guides, Projects, Research
1 / 3
This page cannot be seen from the preview
Don't miss anything!


The object of this project is to setup and solve a nontrivial linear programming problem. The
particular problem we will examine comes from Chapter 13, Section 1 in your book and you are
encouraged to read the discussion found there.
We will use Matlab (which is available on the math department computers) to solve this problem.
Part of the goal of this project is to become familar with solving linear programs on a computer. I
will provide a short tutorial on the use of the Matlab command “linprog” on the course webpage
and possibly discuss it in class.
Introduction
We will solve the problem of selecting an appropriate mix of assets to include in an investment
portfolio. Suppose we are given a selection of n potential investments. We will let Rj denote the
return on investment j in the next investment period. Of course, we do not know a priori the values
of the Rj. They represent the future return on an investment made now. We can, however, try to
estimate the behavior of the Rj using historical data.
Random Variables
In particular, we treat the Rj as random variables — unknown quanitities associated with a prob-
ability distribution. We might not be able to say that Rj will have a particular value in the next
time period, but we are able to estimate the probability that it will have a certain value. For our
purposes, we will only be interested in a single quantity associated with a random variable, the
expected value.
Given a random variable R and a set of observed values x 1 ,... , xn of R, we can estimate the expected
value of R as
n
j
xj.
Let us now consider the particular case of an investment Rj. For each investment j, we will be given
a set
(2) Rj (1), Rj (2),... , Rj (T )
for T previous observations of the return on investment j. This is the historical data available for
each investment. Each observation is the return on that investment over one time interval in the
past. We will then estimate the expected value of the random variable Rj as
(3) ERj ≈
t
Rj (t).
We interpret this quanitity as the amount of money we expect to make in the next investment
interval if we invest one dollar in the j
th investment.
Portfolios
A portfolio is determined by specifying what fraction of one’s assets are put into each asset. That
is, a portfolio is a sequence of nonnegative real numbers x 1 ,... , xn such that
(4) x 1 +... + xn = 1.
The return on a given portfolio in the next time period would then be
j
xj Rj.
1
2
We will call the expected value of R,
j
xj ERj ,
the reward associated with the given portfolio. This is the amount of money we expect — based on
our estimates — to earn in the next investment period for each dollar invested.
There is always a tradeoff between the risk associated with an investment and its rewards. We will
measure the risk associated with single investment Rj as
(7) E |Rj − ERj |.
And we will measure the risk associated with a portfolio as
j
xj (Rj − ERj )
This is, once again, a random variable whose value we do not actually know. Again, we will estimate
it using the historical data available to us. That is, we can estimate the risk associated with the
given portfolio as:
T ∑
t=
j
xj (Rj (t) − rj )
where rj is the estimated expected value of Rj.
The Problem
Our problem is to find an investment portfolio with the right mix of risk and reward. We introduce
a constant μ which measures the amount of risk an investor is willing to take and consider the
problem:
maximize: μ
j
xj ERj − E
j
xj (Rj − ERj )
subject to:
j
xj = 1
(10) x ≥ 0.
Replacing the expected values in (10) with our estimated expected values, we arrive at the problem:
maximize: μ
j
xj rj −
T ∑
t=
j
xj (Rj (t) − rj )
subject to:
j
xj = 1
(11) x ≥ 0 ,
where rj is the estimated expected value
(12) rj =
T ∑
t=
Rj (t).
The Project
absolute values in the objective function by introducing new variables and replacing the inequalities
by equalities by introducing slack variables. Write down your formulation and explain how the
absolute values were elimated.