Due Thursday, 2000 Feb 17, at the beginning of class.
One of the scariest questions retiring people face is whether they will outlive their money. After working for thirty or more years to accumulate money, suddenly the income stops but the expenses do not. Since middle and upper class people can easily live twenty to thirty years after retirement, accurate projections are required. Compounding the fear is the belief that, if the money runs out, it is likely to do so after an age where the person would be willing or able to return to work. On the other hand, people wish to enjoy their retirement and their retirement money so they are loath to lower their standard of living too much. In this homework, we will use historical data to predict the ``probability'' of bankruptcy for a given withdrawal rate.
On the flip side of the gradual reduction of one's investments during retirement is the accumulation of wealth during one's working years. Young workers, who are facing many major expenses, e.g., house, children, and vacations, frequently question if they need to save for retirement at all and, if so, how much. Using historical data, we will write a computer program that we can use to predict how much money a worker needs to save each year to accumulate, say, one million dollars for retirement. (One can determine a reasonable target using the program described in the preceding paragraph.)
1998 February, Trinity University professors Philip L. Cooley, Carl M. Hubbard, and Daniel T. Walz published an article in the American Association of Individual Investors' AAII Journal, volume XX, number 2. Apparently, the article caused quite a stir, receiving publicity in the Morningstar Fundinvestor and on Scott Burns's Money Page. We will create software that is more powerful, and hopefully more useful, that that described by the authors.
(Software like that we will write is for sale as commercial products. With a little more thought and a few features to make it more realistic, we may be able to post it on a web site and perhaps also write a short paper. Please let me know if you are interested. (Please do not let the preceding comment worry you about the program's complexity. It is at the level of a CS1320 programming project.))
Without loss of generality, we will concentrate on the retirement income question.
The question is ``Will I outlive my investments if I withdraw $xdollars every year?'' More specifically, ``What is the probability I outlive my investments if I withdraw $x dollars every year?''
The program's input includes:
For example, suppose one started with $1M invested wholly in large company stocks on 1946 January 01 and withdrew $40K per year at the end of each of two years. Large company stocks in 1946 returned -8.07% so we ended the year with
Investment returns vary on a daily, monthly, and annual basis. If our investment value is ever nonpositive, we ran out of money and declare bankruptcy.
Investments can also be categorized according to type, e.g., large company stocks, long-term corporate bonds, and U.S. Treasury bills. To a first approximation, the return on most investment depends more on in which categories it is invested than on the individual investments within the category. For example, to a first approximation, it matters more that 50% of one's assets are in large company stocks than whether they are in Vanguard's 500 Index Fund than in several individual large-cap stocks. Since we are simulating, we will ignore these distinctions. U.S. Treasury bills are frequently considered ``cash'' since their duration is very short, e.g., three months.
As we might see in a future homework assignment, asset allocation determines, to a first approximation, both the size of return and how much the return varies. Historically, stock returns are largest but also most variable, while U.S. Treasury bill returns are smallest but more predictable. We will assume that our retiring couple has determined their reward-risk tradeoff by allocating assets into categories according to fixed percentages. A typical allocation is 60% large company stocks, 35% long-term corporate bonds, and 5% U.S. Treasury bills. At the end of each year, the couple will rebalance their investment to meet these fixed percentages by conceptually selling assets greater than their desired percentage and buying assets with percentages too low.
Although past performance does not indicate future performance, we will use annual return data from Ibbotson Associates [Ass95]. For each year between 1926 and 1997 inclusive, returns for
To answer our question of whether we will go bankrupt if we withdraw money for n years, we will determine the value of our investment starting in every year y and ending at the beginning of year y + n. For example, suppose we are interested in a ten-year time frame. Then, we determine the value of an investment starting at the beginning of 1926 and ending at the beginning of 1936, the value of an investment from 1927 to 1937, ..., and from 1988 to 1998. For each time period, we record whether we ran out of money or not. The probability of bankruptcy is the number of bankrupt-time periods divided by the total number of periods.
To ease the modeling, let us make a few assumptions:
Write a computer program determining the probability of not running out of money given
One approach to solving this problem is to write a computer program P that has command-line arguments for
I conjecture, but have not verified, that one pass through the data will yield answers for all the years, even without using an array of values for all the current time frames. Why not just use the simpler approach because the program's running time is so short, it is not terribly important.
It would be nice but is not essential that your program be flexible enough to accept monthly data rather than annual data. It would also be nice to accept any number of asset classes. An optional feature would be the ability to specify the frequency of rebalancing.
Your program should be able to recreate all the tables in the article by Cooley, Hubbard, and Walz. Note they use data through 1995, not 1997.
Of course, your program should also be able to do more:
I have also posted my computer program against which you can compare your answers.
I do not know how to validate the results. Does anyone have any ideas?
Write a computer program that determines the probability of accumulating a specific amount of money given
Hint: You should not have to do much work.
Please provide written or typed answers to these questions:
The Ibbotson data is available.
My code, to compute the value of the investment after a particular period of time and starting at a particular year, is available. It runs on my Linux computer. The command line arguments are:
Use any programming language you desire. Grading will be based predominantly on correctness, with a small portion on programming style and your written answers.
I will run your code on a computer science Linux computer so please check that it compiles and runs there. Please check that it compiles and runs without any errors or warnings. For example, the g++ compiler options to produce warnings are -Wall -pedantic. For example, I can compile using
Please submit your code, enough documentation to know how to compile and run your code, and possibly answers to me (oldham@cs.trinity.edu). If you need to submit multiple files, please use a command like
Unlike many other activities in life, it is generally a good idea to incremental write a computer program. That is, start with a simple program, slowing adding features and complexity, being sure to check the program at each step. Here is one way to write the computer program.
If you get stuck, please come see me. Please do not get stuck on the input, output, or command-line arguments; these are not the point of the assignment.
If you need help with the math, come see me but bring your ideas written in math or English. See also the authors' appendix. Note, if the value of an investment goes negative, it should stay negative so there is no reason to abort a computation early.
For the purpose of the program, we need not know the definitions of the different asset classes, but we include them for completeness.