C++ Neural Networks and Fuzzy Logic
by Valluru B. Rao M&T Books, IDG Books Worldwide, Inc. ISBN: 1558515526 Pub Date: 06/01/95 |
Previous | Table of Contents | Next |
The on-balance volume (OBV) indicator was created to try to uncover accumulation and distribution patterns of large player in the stock market. This is a cumulative sum of volume data, specified as follows:
If todays close is greater than yesterdays close
OBVt = OBVt-1 + 1
If todays close is less than yesterdays close
OBVt = OBVt-1 - 1
The absolute value of the index is not important; attention is given only to the direction and trend.
This indicator does for price what OBV does for volume.
If todays close is greater than yesterdays close:
ADt = ADt-1 + (Closet - Lowt)
If todays close is less than yesterdays close
ADt = ADt-1 + (Hight - Closet)
Now lets examine how these indicators look. Figure 14.7 shows a bar chart, which is a chart of price data versus time, along with the following indicators:
Figure 14.7 Five minute bar chart of the S&P 500 Sept 95 Futures contract with several technical indicators displayed.
The time period shown is 5 minute bars for the S&P 500 September 1995 Futures contract. The top of each bar indicates the highest value (high) for that time interval, the bottom indicates the lowest value(low), and the horizontal lines on the bar indicate the initial (open) and final (close) values for the time interval.
Figure 14.8 shows another bar chart for Intel Corporation stock for the period from December 1994 to July 1995, with each bar representing a day of activity. The following indicators are displayed also.
Figure 14.8 Daily bar chart of Intel Corporation with several technical indicators displayed.
You have seen a few of the hundreds of technical indicators that have been invented to date. New indicators are being created rapidly as the field of Technical Analysis gains popularity and following. There are also pattern recognition studies, such as formations that resemble flags or pennants as well as more exotic types of studies, like Elliot wave counts. You can refer to books on Technical Analysis (e.g., Murphy) for more information about these and other studies.
Neural preprocessing with Technical Analysis tools as well as with traditional engineering analysis tools such as Fourier series, Wavelets, and Fractals can be very useful in finding predictive patterns for forecasting.
In this final section of the chapter, we outline some case studies documented in periodicals and books, to give you an idea of the successes or failures to date with neural networks in financial forecasting. Keep in mind that the very best (= most profitable) results are usually never reported (so as not to lose a competitive edge) ! Also, remember that the market inefficiencies exploited yesterday may no longer be the same to exploit today.
Well, Hillary Clinton can certainly trade commodities, but a three-year-old, too? In his paper, Commodity Trading with a Three Year Old, J. E. Collard describes a neural network with the supposed intelligence of a three-year-old. The application used a feedforward backpropagation network with a 37-30-1 architecture. The network was trained to buy (go long) or sell (go short) in the live cattle commodity futures market. The training set consisted of 789 facts for trading days in 1988, 1989, 1990, and 1991. Each input vector consisted of 18 fundamental indicators and six market technical variables (Open, High, Low, Close, Open Interest, Volume). The network could be trained for the correct output on all but 11 of the 789 facts.
The fully trained network was used on 178 subsequent trading days in 1991. The cumulative profit increased from $0 to $1547.50 over this period by trading one live cattle contract. The largest loss in a trade was $601.74 and the largest gain in a trade was $648.30.
Milam Aiken designed a feedforward backpropagation network that predicted Treasury Bill Rates and compared the forecast he obtained with forecasts made by top U.S. economists. The results showed the neural network, given the same data, made better predictions (.18 versus .71 absolute error). Aiken used 250 economic data series to see correlation to T-Bills and used only the series that showed leading correlation: Dept. of Commerce Index of Leading Economic Indicators, the Center for International Business Cycle Research (CIBCR) Short Leading Composite Index, and the CIBCR Long Leading Composite Index. Prior data for these three indicators for the past four years (total 12 inputs) was used to predict the average annual T-Bill rate (one output) for the current year.
Guido Deboeck and Masud Cader designed profitable trading systems for two-year and 10-year treasury securities. They used feedforward neural networks with a learning algorithm called extended-delta-bar-delta (EDBD), which is a variant of backpropagation. Training samples composed of 100 facts were selected from 1120 trading days spanning from July 1 1989 to June 30, 1992. The test period consisted of more than 150 trading days from July 1, 1992 to December 30, 1992. Performance on the test set was monitored every N thousand training cycles, and the training procedure was stopped when performance degraded on the test set. (This is the same procedure we used when developing a model for the S&P 500.)
A criterion used to judge model performance was the ratio of the average profit divided by the maximum drawdown, which is the largest unrealized loss seen during the trading period. A portfolio of separate designed trading systems for two-year and 10-year securities gave the following performance: Over a period of 4.5 years, the portfolio had 133 total trades with 65% profitable trades and the maximum drawdown of 64 basis points, or thousands of units for bond yields. The total gain was 677 basis points over that period with a maximum gain in one trade of 52 basis points and maximum loss in one trade of 47 basis points.
Previous | Table of Contents | Next |