How long do you need to endure when faced with a market downturn ?
Part of the work of being a trainer is that I am relatively free to pursue some research to improve on my training materials so I got back to some R programming this week.
My statistical programming is rusty again and I have to get back to the basics of understanding data frames and how to put simple packages in my R Studio. And this means dealing with some stuff that professionals find trivial like manipulation of dates and processing the finance data from Yahoo Finance.
Fortunately, I was able to get some useful thing done within the last 2 days. I downloaded historical STI information and was able to measure the duration of market crashes.
I wrote a simple program in R to track crashes on the STI.
This program adopts the following rules :
- A crash occurs when the market dips 30% from the previous market peak.
- The timing of the start of the crash will then be set at the timing of the market peak.
- A recovery occurs when the market goes up 30% from the previous market trough.
- The timing of the market recovery will then be set to the timing of the market trough.
From this dump, we can safely say that the longest period that we will need to endure from a market peak to market trough is 2 years. The longest period is not our most recent recession on 2007, but during 1996-1998 when we had the Asian Currency Crises.
My R program allows me to vary the conditions of a crash. If I set a crash to be 10% from a market peak and a recovery to be 10% from a market trough, I will, of course, see a lot more crashes in my program output but with a shorter duration.
Moving forward, this program will be added to my list of teaching materials for my workshop.
And in case you are wondering, we are not in a crash situation yet.
Over the next few weeks, I will be trying to determine whether an objective asset allocation between stocks and bonds would exist. Will post my findings here.