Artfcl tchncl an

463 views
327 views

Published on

Published in: Business, Economy & Finance
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
463
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
4
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Artfcl tchncl an

  1. 1. The Ef cient Market Hypothesis through the Eyes of an Arti cial TechnicalAnalyst: An Application of a New Chartist Methodology to High-FrequencyStock Market DataTimur YusupovDepartment of Economics,University of Kiel,Olshausen Str. 40, Kiel,24118, Germany,yusupov@bwl.uni-kiel.deThomas LuxDepartment of Economics,University of Kiel,Olshausen Str. 40, Kiel,24118, GermanyAbstractThe academic literature has been reluctant to accepttechnical analysis as a rational strategy of traders in -nancial markets. In practice traders and analysts heavilyuse technical analysis to make investment decisions. To re-solve this incongruence the aim of this study is to translatetechnical analysis into a rigorous formal framework and toinvestigate its potential failure or success. To avoid subjec-tivism we design an Arti cial Technical Analyst. The empir-ical study presents the evidence of past market inef cienciesobserved on the Tokyo Stock Exchange. The market can beperceived as inef cient if the technical analysts transactioncosts are below the break-even level derived from technicalanalysis.1. IntroductionFor long time the ef cient market hypothesis (EMH) hasbeen the dominant paradigm nance. Its weak form postu-lates that in a competitive market it should not be pro tableto base investment decisions on information obtained frompast prices or returns of publicly traded securities. Numer-ous empirical studies, however, show that technical analy-sis, which directly contradicts the weak form of the EMH,could exploit to some extent hidden patterns in past prices.To avoid the joint hypothesis problem of direct tests of theEMH, an arti cial technical analyst is created to conduct thetest. This approach has two advantages. First, it is free ofequilibrium model limitations, and second, technical analy-sis can be tested in a robust way, which should validate itsexistence.Corresponding author.The EMH is the cornerstone of modern nancial eco-nomics. The paradigm was coined in the 1960-70s by HarryRoberts [133] and formalized by Eugene Fama [50]. Theyidenti ed three forms of market ef ciency distinguishedby which information prices of securities should correctlyincorporate. The weak form of market ef ciency postu-lated that past prices or returns should have no information,which can be used to predict next period values. This formwas linked to the random walk hypothesis, which consti-tuted the majority of tests performed that time. The weakform EMH was supported by empirical studies conductedbefore and shortly after the 1970s. Its association to the ran-dom walk allowed the development of many important an-alytical tools in nancial theory. The most famous exampleis the application of the random walk hypothesis by MyronBlack and Fischer Scholes [21] to derive their seminal op-tion pricing formula, which has caused a boom of derivativemarkets and further developments in nancial theory.With the development of statistical techniques more andmore deviations from the random walk hypothesis were ob-served in time series of prices. Finally, Andrew Lo andCraig MacKinlay [100] used a simple speci cation test toreject the random walk hypothesis for stock prices and re-turns. The test was based on the variance properties of ran-dom walk time series. It is robust to different heteroskedas-ticities and non-normality of data. In reaction to this theassumptions of the random walk hypothesis were relaxed,rst, to allow only independence of increments, and, later,to require only zero correlation of increments.In the 1980s technical analysis appeared as a new as-pect in the empirical literature on testing the EMH. Thisapproach, reported to be wide-spread among professionalnancial practitioners, attempts to exploit predictability ofprices for pro t, and thus is in direct contradiction to theweak form of market ef ciency. For example, in 1989 He-
  2. 2. len Allen and Mark Taylor [5] surveyed that at the shortesthorizons, intraday to one week, approximately 90% of re-spondents [professional traders and analysts at foreign ex-change markets] used some chartist input in forming theirexchange rate expectations, with 60% judging charts to beat least as important as fundamentals. Moreover, there ap-peared to be a persistent 2% of presumably "pure" chartists,who only used technical analysis. Numerous empiricalstudies reported either pro tability of technical analysis orits positive added value to investment decision making.Along with the empirical studies nancial theory turnedits attention to technical analysis. This paradigm was in-corporated in behavioral asset pricing models to capture ob-served empirical "anomalies", like volatility clustering, hightransaction volumes and erratic behavior of prices [17]. Itwas persuasively shown that technical analysis could bringadditional information, and as such should be used by ra-tional investors [22, 27]. Moreover, the application of tech-nical analysis for speculation can produce stable equilib-ria in an economy [113]. In the extreme case, the domi-nance of an "irrational" technique, which technical analysiswas referred to be, in the market can create its own space,where application of other "rational" techniques is subop-timal [45]. At present technical analysis and market ef-ciency are studied from a behavioral prospective, whichpromises to resolve their incongruence.Since the original formulation of the weak form of theef cient market hypothesis became outdated, the empiri-cal implementation of the EMH experienced several trans-formations. First, unpredictability of prices was replacedby inability to outperform passive benchmarks, such asthe buy-and-hold strategy, and later, by adding the aspectof pro tability. In this formulation a nancial market isweakly ef cient if an outcome of market interactions doesnot contain any information, which can be persistently andpro tably exploited by predicting the next period prices orreturns. The notion of pro tability is taken in a strict sense,that is all transaction costs should be accounted for.With the rst formulation of the EMH, it became obvi-ous that its tests might be sensitive to the joint hypothesisproblem. Evidence against the EMH could be either dueto a wrong equilibrium model or due to true market inef -ciency. One way to avoid this problem is to construct teststhat do not assume any underlying model.Technical analysis stands in direct contradiction to theweak form of the EMH, and as such can be directly used forits testing. The design of the test is as follows. One shouldprocess past stock prices with technical analysis to obtainnext period price predictions. Predicted values should beused in hypothetical investment decisions. Associated re-turns, adjusted for transaction costs, should be aggregatedand can be used as a measure of nancial market inef -ciency if they are in excess of a passive benchmark.Normally the application of technical analysis suffersfrom subjectivism. Technical analysis is taken rather as anart than a precise science. The application of principles oftechnical analysis in an autonomous or arti cial decision-making system should eliminate the subjective factor. Ad-ditionally, the system should be relatively simple to insureits robustness, and transparent to provide its understandabil-ity. Spyros Skouras [143] proposed an arti cial technicalanalyst as a quanti able measure of market ef ciency. Ex-panding his idea, an arti cial technical analyst (ATA) willalso be used for our test.Our idea of creating and employing the ATA originatesfrom the seminal paper by Arthur et al. [9]. The authorshave created the Arti cial Stock Market (ASM), known asthe Santa Fe ASM. The market is populated by arti cialagents engaged in stock trading. The agents use technicalanalysis to screen the market and an implementation of ar-ti cial intelligence, Learning Classi er Systems (LCS), forthe optimal application of technical trading rules.The success of the Santa Fe ASM inspired us to createthe ATA. Unfortunately, the Santa Fe ASM had some short-comings: computational and algorithmic limitations of thattime, and a short and xed list of technical trading rules.Additionally, the mechanism of forming the traders expec-tations was based on early concepts of LCS that have under-gone important modi cations in the meantime. Our imple-mentation takes into account the shortcomings of the SantaFe ASM. It incorporates technical analysis in an adaptiveway, where the core of the ATA is driven by a new imple-mentation of LCS.This new implementation of the ATA incorporates threemain components: data-preprocessing, pattern-recognitionand decision-making under transaction costs. The rst com-ponent insures that raw input data are homogenized in away that maximizes the informational content. Homoge-nization itself allows to reduce the complexity of pattern-recognition, by focusing attention only on levels in time se-ries. The pattern-recognition is driven by an implementa-tion of arti cial intelligence, which allows for a transparentstructure of the results. LCS was selected as a possible can-didate. To match the required level of performance a new al-gorithm is used - denoted as True Classi er System (TiCS).The decision-making under transaction costs insures opti-mality of investment decisions.In the empirical part the ATA is applied to historical timeseries of security prices. Since the part of economically rel-evant transaction costs is the impact on the price, in a studyof hypothetical investments with historical data the aspectof pro tability is inverted. Instead of measuring the aggre-gate return adjusted for speci ed transaction costs, the valueof revealed transaction costs, which insure positive aggre-gate return, is used. This allows to derive breakeven trans-action costs, which could be later used for benchmarking
  3. 3. markets, segments, and individual stocks.This work differs from others in the extent to which thedesign of the market ef ciency test is free of equilibriummodel limitations. By applying technical analysis one cansee whether price time series have predictable patterns. Incase persistent patterns are detected, their pro tability canbe studied under the schedule of revealed transaction costs.In this way an absence of patterns is a clear indication of theweak form of market ef ciency, which was advocated in thetheoretical literature of the 1970s. Otherwise, the pro tabil-ity of detected patterns is accessed through revealed trans-action costs. When the level of breakeven transaction costsis below market transaction costs, a market can be perceivedas ef cient, according to the pertinent literature. At thesame time a comparison to market transaction costs leaves aspeculative space for those market participants, whose cor-rectly accounted transaction costs are below the breakevenvalue.The novelty of this work comes, rst, from using anadaptive method of technical analysis, which allows to ex-tract uncharted patterns; second, from developing a newtype of pattern-recognition engine, which makes detectedpatterns accessible afterwards; and, third, from testing mar-ket ef ciency under a wide schedule of transaction costs,which allows to identify boundaries of market ef ciency.This paper is organized as follows. Section 2 presentsan overview of the ef cient market hypothesis. It is fol-lowed by Section 3, which discusses the impact of transac-tion costs on the perception of market ef ciency. Section4 outlines the counterpart of the weak form of market ef -ciency - technical analysis. Section 5 introduces the designand key components of the ATA. Data used in empiricalstudies are presented in Section 6 along with a short de-scription of the Tokyo Stock Exchange microstructure. Re-sults of hypothetical empirical application are presented inSection 8. Conclusion nalizes the paper.2. Ef cient Market HypothesisThe origin of the EMH dates back to 1900, when LouisBachelier [12] rst introduced the idea that the stock mar-ket uctuations follow a stochastic process for which the fu-ture does not depend on the past except through the presentand the best prediction of the subsequent price is the valueof the current price.1That is if all relevant information isalready contained in the quoted prices, the only cause ofnew variations could be elements of information that arenot predictable. Bachelier already stresses the importanceof the information concept, on which the ef ciency concept1This notion was later branded by Karl Pearson as the random walkhypothesis [125, 126].is based.2The notion of "ef cient markets" was coined by HarryRoberts and popularized by Eugene Fama. In his Ph.D. dis-sertation Fama convincingly made the argument that in anactive market that includes many well-informed and intel-ligent investors, securities will be appropriately priced andwill re ect all available information. If a market is ef cient,no information or analysis can be expected to result in out-performance of an appropriate benchmark.It has been customary since Harry Roberts [133] to dis-tinguish three forms of market ef ciency by consideringthree different types of information sets:The weak form of the EMH asserts that prices fullyre ect the information contained in the historical se-quence of prices. Thus, investors cannot devise an in-vestment strategy to yield abnormal pro ts on the basisof an analysis of past price patterns.3The semi-strong form of the EMH asserts that currentstock prices re ect not only historical price informa-tion but also all publicly available information relevantfor company securities. If markets are ef cient in thissense, then an analysis of balance sheets, income state-ments, announcements of dividend changes or stocksplits or any other public information about a companywill not yield abnormal economic pro ts.The strong form of the EMH asserts that all informa-tion that is known to any market participant about acompany is fully re ected in market prices. Hence,not even those with privileged information can makeuse of it to secure superior investment results. There isperfect revelation of all private information in marketprices [105].These de nitions of the variants of the EMH allows toconstruct tests focused on their speci c aspects. Accep-tance or rejection of some form of market ef ciency allowsto identify the level of nancial market development. Ob-tained results can be used to generate recommendations andpolicies to improve ef ciency of nancial markets.Theoretical arguments for the ef cient market hypothe-sis are based on three assumptions. These are the rational-ity of investors, the irrationality of investors and the ran-domness of trades and, nally, the presence of rational arbi-trageurs. Each assumption is progressively weaker but their2However, as Paul Cootner [36] comments - Bacheliers work receivedlittle attention from academicians and was forgotten for almost fty veyears. His work was rediscovered in 1955 by Leonard Jimmie Savage.3The de nition of Mark Rubinstein in [137] and William Beaver in[16] requires that publishing the information does not change equilibriumprices. Rubinsteins notion allows one to ask only if the market is ef cientwith respect to all information. William Beaver provides a de nition thatcovers the information contained in historical prices.
  4. 4. combination allows to justify market ef ciency in the mostof market situations.Rationality of investors. Investors are assumed to be ra-tional and hence to value securities rationally. Investorsvalue each security for its fundamental value. When in-vestors learn something new about the fundamental valuesof securities, they quickly respond to the new informationby bidding up prices (buying securities) when the news isgood and bidding them down (selling) when the news isbad. As a result, security prices incorporate all the avail-able information almost immediately and adjust to new lev-els corresponding to the new net present values of expectedcash ows.Irrationality of investors and randomness of trades. Itis often admitted by proponents of the EMH that someinvestors are not rational, and they are trading randomly.When there is a large number of such investors and whentheir trading strategies are uncorrelated, their trades arelikely to neutralize each other.4Presence of rational arbitrageurs. Although some in-vestors might be irrational in a similar way there are somerational arbitrageurs in the market. Arbitrage5is one ofthe most intuitively appealing and plausible arguments inall of economics. The main condition for arbitrage is theexistence of an over- or undervalued security with a closesubstitute.6This could be the case when the trade involvesirrational investors. Noting the overpricing the arbitrageurwould sell (or even short sell) the overpriced security andsimultaneously purchase another, “essentially similar” buttruly valued, security to hedge any risk. The effect of this ar-bitrage is to bring the price of the overpriced security downto its fundamental value.The arbitrage argument allows to cover the most com-plex case - the existence of irrational investors. To the ex-tent that the securities that irrational investors are buyingare overpriced and the securities they are getting rid of areundervalued, such investors earn lower returns than eitherpassive investors or arbitrageurs. Relative to their peers, ir-rational investors lose money and in a long run should leavethe market. Thus, not only investor rationality, but also themarket forces bring about the ef ciency of nancial markets[142].Since this work is presenting the ef cient market hypoth-esis from the point of view of technical analysts this studyfocuses on the weak form of ef ciency and its tests.The earliest tests were concerned with short horizon re-turns. These tests typically assumed that in an ef cient mar-4In such a market, there will be a substantial trading volume as theirrational investors exchange securities with each other, but the prices arenonetheless close to their fundamental values.5That is the simultaneous purchase and sale of the same, or essentiallysimilar, security in two different markets at advantageous different prices.6In some cases the access to alternative markets can be taken as a formof substitute.ket the expected rate of return was constant through timeand the realized returns should not be serially correlated.Eugene Fama [49] nds that the rst-order autocorrelationof daily returns is positive. In [106] and [49] it is also recog-nized that returns are characterized by volatility cluster-ing and leptokurtic unconditional distributions. LawrenceFisher [60] suggests that autocorrelations of monthly re-turns of a diversi ed portfolio are bigger than those of indi-vidual stocks. However, the evidence often lacked statisticalpower and the EMH was not rejected.7Later research used daily and weekly NYSE or AMEXdata. Andrew Lo and Craig MacKinlay [100] nd thatweekly returns on portfolios of NYSE stocks show reli-able positive autocorrelation, which is stronger for portfo-lios of small stocks. This can be due to their smaller liq-uidity and the non-synchronous trading effect discussed al-ready in [60]. In [35] Jennifer Conrad and Gautam Kaulmitigated this problem, examining the autocorrelations ofWednesday-to-Wednesday returns for size-grouped portfo-lios. They also found positive autocorrelation especially inportfolios of small stocks.However, in [79] Shmuel Kandel and Robert Stambaughshow that stock return predictability, which seems weakwhen evaluated by classical statistical criteria, may never-theless be economically important in the sense that a ra-tional Bayesian investors would substantially alter portfolioholdings in response to the current values of predictive vari-ables.As noted by Francis Diebold [46] and Robert Cumbyand John Huizinga [38], the presence of conditional het-eroskedasticity or excess kurtosis biases the test towards re-jection of the null hypothesis of uncorrelated returns. Incontrast to the weak evidence for autocorrelation in returns,Tim Bollerslev and Robert Hodrick [24] stress the impor-tance of conditional heteroskedasticity. One should, how-ever, say that nding a strong dependence in the even or-dered moments does not necessarily imply market inef -ciency, which is consistent with a martingale hypothesis forstock prices.Overall, many researches showed that daily and weeklyreturns are predictable from past returns. Thus, these empir-ical ndings reject the weak form of the EMH. At the sametime the estimated autocorrelations are typically found to bevery small and the variation of these returns is a small partof the overall return variance.In recent times the return predictability research gradu-ally moved in the direction of higher frequency time series.In [80, 81] Ludwig Kanzler developed a new version of theBDS test to verify the EMH on ultra-high frequency foreignexchange market data. He found that the EMH holds onlyin some periods, in particular, when a release of importantnews takes place.7Reported R2 was often less than 0:01 for individual stocks.
  5. 5. The more striking evidence on the predictability of re-turns from past returns comes from tests on predictabilityof long-horizon returns. Robert Shiller [141] and LawrenceSummers [145] challenge the argument of EMH validity,based on very low autocorrelations of short-horizon re-turns. They provide evidence of stock market inef ciencyby demonstrating that stock prices undergo large slowly de-caying swings, even though the short-term returns have littleautocorrelation.In [42, 43] Werner DeBondt and Richard Thaler attackedmarket ef ciency in a similar manner, trying to unmask ir-rational bubbles. They nd that the NYSE stocks identi edas the most extreme losers over a 3- to 5-year period tendto have strong returns relative to the market during the fol-lowing years. The stocks identi ed as extreme winners tendto have, on the contrary, weak returns relative to the mar-ket. They attribute these results to market overreaction toextreme news.In [77] Narasimhan Jegadeesh and Sheridan Titman ob-served that past winners realized consistently higher re-turns around their earnings announcements in the rst 7months following the portfolio formation date than pastlosers. They argue that to attribute the results to underre-action is overly simplistic. Buying past winners and sell-ing past losers, consistent with positive feedback trading,moves prices further from their long-run values and therebycauses price to overreact. The interpretation is consistentwith DeLong et al. [44] who explore the implications ofpositive feedback trading on market prices. Louis Chan [32]and Ray Ball and S. P. Kothari [13] argue that these resultsare due to a failure to risk-adjust returns.James Poterba and Lawrence Summers [127] and Eu-gene Fama and Kenneth French [54, 55] also realized thatthe negative serial correlation in returns would manifestmore transparently at longer horizons. Evidence in [127]and [54], using multi-period regressions and variance ratiostatistics, suggests that for longer return horizons a largeproportion of returns is explainable from the history ofpast returns alone.8James Poterba and Lawrence Summers[127] argue that asset prices are characterized by specula-tive fads, in which market prices experience long systematicswings away from their rational fundamental values.However, whether the longer-horizon mean reversion re-ally exists is controversial. For example, Narasimhan Je-gadeesh [76], Kim et al. [84], Mankiw et al. [107], Richard-son et al. [130], all argue that the case for predictabilityof long-horizon stock returns is weak when one correctsfor the small sample biases in test statistics. In addition,[54] offers the counterargument that irrational bubbles and8The estimated in [54] for monthly U.S. stock returns imply that for3- to 5-year returns up to 40% of variability is predictable. However, thisdoes not necessarily imply market inef ciency, since the variation could bedue to a time-varying risk premium.swings in stock prices are indistinguishable from rationaltime-varying expected returns.The subsequent work showed, that the apparent pre-dictability of long-horizon returns should be interpretedvery carefully. As [24] point out, the overlapping natureof the data in the multi-year return regressions gives rise toa non-standard small sample distribution of test statistics,which appear to be better approximated by the alternativeasymptotic distribution derived by Richardson et al. [130].In [24] Tim Bollerslev and Robert Hodrick developedtests based on the iterated version of the null hypothesis us-ing Hansens GMM [68] and found some improvement inthe small sample performance of the test statistics. How-ever, they conclude that there is still little evidence for pre-dictability of returns.To sum up, the degree of predictability is generally smallcompared to the high variability of returns. In [52] Eu-gene Fama supports this argument saying that market anom-alies are chance events, i.e. they split randomly betweenoverreaction and underreaction to news (see for example[2, 10, 111, 136]) and they tend to depend on the methodol-ogy used.In the 1970s researchers interested in the ef ciency ofasset markets shifted their focus from the predictability ofreturns to the volatility of prices. The main reason was thatprice uctuations seemed to be too large to be justi ed bythe subsequent variation in dividend payments. The EMHcould not be tested directly but only as a part of a joint hy-pothesis. Researchers were still required to specify a par-ticular model of expected returns. In addition, the predic-tions of price volatility depended on the assumed time se-ries properties of the dividend process and the informationsets of economic agents [24].Stephen LeRoy and Richard Porter [98] and RobertShiller [139, 140] introduced another important class oftests for market ef ciency: the volatility or variance boundstests. They assumed a constant expected rate of returnmodel and reported overwhelming rejections of market ef-ciency since excess price volatility was supposed to implymarket inef ciency.In the rst generation of volatility tests the null hypoth-esis was taken to be the standard present value model witha constant discount rate. The vast majority of these testsresulted in clear rejections of market ef ciency, with actualasset prices being excessively volatile compared to the im-plied price series calculated from the discounted value ofthe expected or actual future fundamentals. One possibleexplanations was the idea that asset prices may be charac-terized by self-ful lling speculative bubbles that earn thefair rate of return but cause prices to differ from their ratio-nal fundamentals.However, as Charles Nelson [120] and Eugene Fama andWilliam Schwert [56] showed in their works, the assump-
  6. 6. tion of constant expected return was unjusti ed. In responseto this problem, subsequent research, in particular by Mar-jorie Flavin [61], Allan Kleidon [85, 86] and Eugene Fama[51] questioned the small sample statistical properties ofthese analyses.9The volatility tests thus clearly show that expected re-turns vary through time, but give no help on the central issueof whether the variation in returns is rational.10The introduction of the option pricing theory by My-ron Black and Fischer Scholes [21] in the 1970s and 1980sturned the attention of the nancial community to derivativemarkets. A. L. Tucker [156] studied the currency optionmarkets. After accounting for transaction costs and bid-askspreads he reported no possibility to earn riskless arbitragepro ts on the currency options market. James Bodurtha andGeorges Courtadon [23] achieved similar results. The cur-rency option market was inef cient only before adjustingfor transaction costs. However, the violations of the EMHdisappear when transaction costs are taken into account.Y. P. Chung [33] investigated the ef ciency of the mar-ket for stock index futures and the pro tability of index ar-bitrage. The results indicate that the size and frequency ofboundary violations decreased signi cantly over the sampleyears for all levels of transaction costs, which indicates ma-turing of the futures market in which arbitrage trading hastended to correct mispricing.In the process of testing the EMH a fundamental prob-lem became obvious. It is known as the joint hypothe-sis test of the EMH. The problem comes from underlyingprobabilistic assumptions. One cannot speak of ef ciencyby itself, except through a model that de nes the genera-tion of prices with a representative probability system. Eu-gene Fama [50, 51] stressed that the market ef ciency perse is not testable. One can test whether information is prop-erly re ected in prices in the context of a pricing model. Itmeans that when one nds anomalous evidence on the be-havior of prices or returns it is ambiguous if this is causedby market inef ciency or/and a bad model of market equi-librium. This leads to the conclusion that the ef ciency testsare always joint tests on the market ef ciency and the pric-ing model and its probabilistic assumptions.In [157] Christian Walter considers this overlap as acommon cause of misinterpretations and errors, leading torejection of ef ciency when there is only a misspeci cationof the stochastic process.9For a survey of this literature see [64].10The efforts of Sanford Grossman and Robert Shiller in [66] and JohnCampbell and Shiller in [31] to resolve this issue ran into the joint hypoth-esis problem of testing market ef ciency jointly with the hypothesis thattheir consumption-based asset pricing model capture all rational variationin expected returns.3. Transaction CostsAt the end of the 1970s and beginning of the 1980s anincreasing number of studies reported the violation of theweak form of market ef ciency. In-depth analyses showedthat the EMH does not rule out small abnormal returns be-fore accounting for transaction costs. Given that collectingand processing information is a costly process, prices areexpected to re ect information to the point where the mar-ginal bene ts of acting on information do not exceed themarginal costs [67, 78].Steven Thorley [154] de nes four components of trans-action costs: brokerage commissions, bid-ask spreads,taxes, suboptimal diversi cation and research.11Based onthe performed simulations he states that 67% of portfoliosare underperforming when transaction costs are correctlytaken into account. Thus, bravado reports of practitionersbeating the market could be just a result of myopic account-ing, but not of market inef ciency.John Hussman [75] argues that transaction costs createa region in which the market may be inef cient while stillexcluding the possibility of abnormal risk-adjusted returns.If suf ciently high trading costs reduce long-term returnsbelow those of a passive approach, an active approach maystill be optimal from the standpoint of utility maximizationfor “myopic” investors whose utility is de ned over the se-quence of returns during individual holding periods, insteadof terminal wealth.Analysts could therefore still have an incentive to ob-tain and act on valuable information. As Elroy Dimson andMassoud Mussavian [47] suggest, time-varying expectedreturns could also explain these patterns.To sum up, transaction costs, in particular bid-askspreads, are one of the main reasons for rejecting the EMH.That is the stock market is ef cient when transaction costsare considered [11]. Correct accounting for transactioncosts can remove perception of market inef ciency. Thus,the magnitude of transaction costs is crucial for measuringmarket ef ciency.4. Technical AnalysisThere are two competing ways to forecast the price de-velopment of nancial instruments: fundamental and tech-nical analysis. The fundamental analysis relies on the fun-damental attributes of the instrument, such as price/earningratio, return on investment and associated economic statis-tics. The aggregation of these measures provides an intrin-sic value of the instrument, which in an ef cient nancialmarket should be equal to the trading price of the instru-ment. Unfortunately, this is not the case observed in reality.11One would additionally include impact on the price since in a lowliquidity market an actual transaction can dramatically shift the price level.
  7. 7. The existence of a human factor brings distortions causingdeviations of the trading price from its intrinsic value. Tech-nical analysis is aimed at detecting a psychological compo-nent of nancial trading and consequently converting nd-ings into pro t.Technical analysis is the practice of identifying recur-ring patterns in historical prices in order to forecast futureprice trends.12The technique relies on the idea that, as Mar-tin Pring [129] puts it - prices move in trends which aredetermined by the changing attitudes of investors toward avariety of economic, monetary, political and psychologicalforces. Detection of trends is performed through indicatorsor technical rules which are aimed to capture underlying de-pendencies.The Japanese were the rst to use technical analysis totrade rice on the Dojima Rice Exchange in Osaka as early asthe 1600s. A Japanese man called Munehisa Homma whotraded in the futures markets in the 1700s discovered that al-though there was a link between supply and demand of rice,the markets were also strongly in uenced by emotions oftraders. As a result there could be a vast difference betweenthe value and price of rice. Homma realized that he couldbene t from understanding the emotions to help predict thefuture prices. He formulated his trading principles in twobooks, Sakata Senho and Soba Sani No Den, which weresaid to have been written in the 1700s. His work, as appliedto the rice markets, evolved into the candlestick methodol-ogy which is still popular among chartists in Japan. Unfor-tunately, the results of four hundred years old studies wereisolated by cultural and language barriers from the westernworld up to a moment when they have been rediscovered inthe second half of 20th century [121, 161].In the western world technical analysis starts in the early20th century with the Dow theory. The theory was devel-oped by Charles Dow based on his analysis of market priceaction in the late 19th century. Charles Dow never wrotea book or scholarly article on his theory. Instead, he putdown his ideas of stock market behavior in a series of edito-rials that The Wall Street Journal published around the turnof the century. In 1903, the year after Dows death, S. A.Nelson compiled these essays into a book entitled The ABCof Stock Speculation. In this work, Nelson rst coined theterm "Dows Theory". In 1922, William P. Hamilton cat-egorized and published Dows tenets in a book titled TheStock Market Barometer. Robert Rhea developed the the-ory even further in the Dow Theory (New York: Barrons),published in 1932 [115].The Dow theory addresses the fundaments of technicalanalysis as well as general principles of nancial markets,which are primarily applied to stock indexes. The theory12John Murphy [114] de ned the technical analysis, as a study of marketaction, primarily through the use of charts, for the purpose of forecastingfuture price trends.assumes impossibility of manipulating the primary trend13,while at short time intervals or with individual stocks themarket could be prone to manipulation by large institutionalinvestors, speculators, breaking news or rumors [131].William Hamilton and Charles Dow openly admitted thatthe Dow theory is not a sure- re means of beating the mar-ket. It is looked upon as a set of guidelines and principlesto assist investors with their own study of the market. TheDow theory was thought to provide a mechanism to helpmake decisions less ambiguous [131].During the 1920s and 1930s, Richard W. Schabacker re-ned the subject of the Dow theory in a somewhat newdirection. He realized that whatever signi cant action ap-peared in a stock index it must derive from similar actionin constituent stocks. In his books, Stock Market Theoryand Practice, Technical Market Analysis and Stock MarketPro ts, Schabacker showed how the principles of the Dowtheory can be applied to the charts of individual stocks [48].Further development of technical analysis was prettystraightforward. First, Richard Schabacker, the interpreterof the Dow theory, was joined by Robert D. Edwards. Then,in 1942 John Magee joined the study of technical analy-sis. With his participation the entire process of technicalevaluation became more scienti c. As a result of their re-search from 1942 to 1948, Edwards and Magee developednew technical methods of technical analysis. They put thesemethods to practical use in actual market operation. Andeventually, in 1948, these ndings were published in theirde nitive book, Technical Analysis of Stock Trends [48].The 8th edition of this book was published in 2001. Itdemonstrates strong interest of investors in methods of tech-nical analysis.Technical analysts distinguish ve points, which de nethe importance of technical analysis [121]:1. While fundamental analysis may provide a gauge ofthe supply/demand situations, price/earnings ratios,economic statistics, and so forth, there is no psycho-logical component involved in such analysis. Techni-cal analysis provides the only mechanism to measurethe "irrational" (emotional) components present in allmarkets.2. The application of technical analysis allows investorsto separate investment decisions from investors senti-ments and to see the market without the prism of sub-jectivity.3. Following technical analysis is important even if onedoes not fully believe in it. This is because, at times,technical analysts themselves are the major reason for13Primary trend is a long-running (up to ve years) general movementin price data.
  8. 8. a market move. Since they are a market moving factor,they should be monitored.4. People remember prices from one day to the next andact accordingly. Peoples reaction affect prices, butprices also affect peoples reactions. Thus, price itselfis an important component in market analysis.5. The price change is the most direct and easily acces-sible information of the combined effect of differentfactors.All but the second point seem to be acceptable. Thesecond point is unrealistic since it requires enormous self-control of a technical analyst. To make it valid one wouldneed a machine with intelligence and expertise of a techni-cal analyst and zero whatsoever emotions.Following the classi cation by Christopher Neely [117]the methods of technical analysis attempt to identify trendsand reversals of trends. To distinguish trends from shorter-run uctuations, technical analysts employ two types ofanalysis: charting and technical (mechanical) rules. Chart-ing, the older of the two, involves graphing the history ofprices over some period - determined by a practitioner - topredict future patterns in the data from the existence of pastpatterns.14The second type of methods, technical rules, im-poses consistency and discipline on technical analysts by re-quiring them to use rules based on mathematical functionsof present and past prices.To identify trends through the use of charts, technicalanalysts must rst nd peaks and troughs in the price series.A peak is the highest value of the price within a time intervalunder consideration (a local maximum), while a trough isthe lowest value the price has taken on within the same timeperiod (a local minimum). A series of peaks and troughsestablishes downtrends and uptrends, respectively.Detecting a trendline allows technical analysts to issue ashort-term investment recommendation. Usually if an up-trend is detected the recommendation is a long position, al-ternatively, for the downtrend it is a short position.Spotting the reversal of a trend is just as important asdetecting trends. Peaks and troughs are important in identi-fying reversals too. Local peaks are called resistance levels,and local troughs are called support levels. If the price failsto break a resistance level (a local peak) during uptrend pe-riod, it may be an early indication that the trend may soonreverse.Technical analysts identify several patterns that are saidto foretell a shift from a trend in one direction to a trendin the opposite direction. The best known type of rever-sal formations called "head and shoulders". The head andshoulders reversal following an uptrend is characterized by14Its advocates admit that this subjective system requires analysts to usejudgement and skill in nding and interpreting patterns [117].three local peaks with the middle peak being the largest ofthe three. The line between the troughs of the shouldersis known as the "neckline". When the price penetrates theneckline of a heads and shoulders, technical analysts con-rm a reversal of the previous uptrend and issue a recom-mendation to take a short position.15Another method of charting is the candlestick techniquedeveloped in Japan more than four centuries ago for riceand its futures market. The technique is based on the recog-nition of visual patterns that take the shape of candlesticks.Every candle includes information on the high, low, open-ing and closing prices of a particular time interval. The g-urative "body" shows the difference between opening andclosing prices, and its length depends on this difference. Ifthe closing price is higher than the opening price, the bodyis white, which signals rising prices. If the opening priceis higher than the closing price, the body is black, whichsignals falling prices. Above and below the candles bodyare the "shadows", called upper shadow and lower shadow.They depict the high and the low of the trading interval [62].In general, the candlestick technique consists of a set of pat-terns, de ned by candlesticks, and respective expectationsof market reaction.The advantage of candlestick technique is that, rst, it al-lows to express several relative to each other values withinone graphical symbol.16Second, this technique can be eas-ily combined with other charting methods or with technicalrules.In general, the problem with charting is that it is verydependent on the interpretation of a technical analyst whois drawing the charts and interpreting the patterns. Subjec-tivity can permit emotions like fear or greed to affect thetrading strategy. Technical rules make the analysis moreconsistent and disciplined and thus allow to avoid the prob-lem of subjective analysts judgment [117].There are many types of technical rules. In general, theyaim at identifying the initiation of new trends. The bestknown technical rules are the following:1. Filter rules - buy when the price rises by a given pro-portion above a recent through.2. Trading Range Break or Channel rules - buy when theprice rises by a given proportion above a recently es-tablished trading range.3. Moving Average rules - buy when the current pricelevel is above the moving average.4. Moving Average Intersection rules - buy when ashorter moving average penetrates a longer moving av-erage from below. They can have a form of Variable15For more details and examples of charting technique see [48, 115].16In this way it is similar to hieroglyphics, where each symbol is a wordor a combination of words.
  9. 9. Length Moving Average or Fixed Length moving aver-age, which differs in the number of days during whichthe buy or sell signal is assumed to be issued.5. Oscillator rules - buy (sell) when the oscillator indextakes an extremely low (high) value. A simple typeof oscillator index is a difference between two movingaverages with short and long horizons [94, 117].6. Statistical rules are based upon ARMA-family mod-els for rescaled returns. The rules rely on a standard-ized forecast, given by the one-period-ahead forecastdivided by an estimate of its standard error. For ex-ample, for ARMA(1; 1) an upward trend is predictedwhen the value of the standardized forecast is positive[153].7. Other rules. Many technical analysts assign a spe-cial role to round numbers in support or resistance lev-els, and to historical record prices.17Other prominenttypes of technical analysis use exotic mathematicalconcepts such as Elliot wave theory and/or Fibonaccinumbers.18Finally, technical analysts sometimes usetechnical analysis of one markets price history to takepositions in another market, a practice called intermar-ket technical analysis [117].Each rule has a mirror equivalent, which suggests shortposition. In each case a technical analyst has to choose thetime horizon over which troughs and peaks are identi edand moving averages calculated as well as the threshold be-fore a decision is made.Since the introduction of technical analysis there is agrowing evidence that many contemporary professional in-vestors use it. The pro tability of technical analysis wouldbe in contradiction to the EMH, which postulates that in ef-cient markets it is impossible to pro t by predicting pricedevelopment based on its past performance.Alfred Cowles [37] was one of the rst scholars who an-alyzed the pro tability of technical analysis. In 1933 hereported results of a hypothetical investment strategy basedon market forecasts of William Hamilton in his editorialsto The Wall Street Journal. The hypothetical applicationof published forecasts of the stock market based on theDow theory over a period of 26 years, from 1904 to 1929,achieved a result better than what would be ordinarily re-garded as a normal investment return, but poorer than theresult of a continuous outright investment in representativecommon stock for this period.The study of Harry Roberts [132] conducted in 1959on American data, for both indexes and individual stocks,17One can argue that this rule captures the effect of the "psychological"barrier, which market has to overcome.18To get more details on Elliot wave theory and Fibonacci numbers see[114].questioned the applicability of technical analysis since timeseries of prices seemed to follow an extremely simplechance model. He referred to Maurice G. Kendall [82],who obtained the same results for British stock indexes andAmerican commodity prices in 1953. Moreover, Robertsfound that even in 1934 Holbrook Working [162] achievedthe same conclusion: that [ nancial] time series commonlypossess in many respects the characteristics of series of cu-mulated random numbers.In contrast to these results Hendrik S. Houthakker [73]in 1961 found elements of non-randomness in speculativeprice movements. He presented evidence that stop ordersgave rise to a non-random pro t. Sidney S. Alexander [3]by using 5-percent ltering of noise showed that after l-tering large changes are more likely to continue than to re-verse: in speculative markets price changes appear to followa random walk over time, but a move, once initiated, tendsto persist.Robert Weintraub [158] analyzed the pertinent literatureof that time on testing technical analysis. He found thatthe studies up to 1963 were using too restrictive assump-tions about the behavior and abilities of technical analysts.For example, Weintraub argued that Kendalls assumptionof xed interval between trades did not re ect the realityand did reduce potential pro t opportunities. By using amore realistic varying waiting time Weintraub obtained re-sults which spoke more in favor of technical analysis thanthe random walk hypothesis. He concluded that the lack ofserial correlation between rst differences of closing pricessimple meant that speculators [technical analysts] who weresupposed to smooth out price movements over time weredoing their job well.In 1964 Sidney S. Alexander [4] tested a number of l-ter rules. Although they appeared to yield returns above thebuy-and-hold strategy for the DJIA and S&P stock indexes,he concluded that adjusted for transaction costs, the lterrules were not pro table. Eugene Fama [49] came to aneven more restrictive conclusion: the data seem to presentconsistent and strong support for the [random walk] model.This implies, of course, that chart reading [technical analy-sis], though perhaps an interesting pastime, is of no realvalue to the stock market investor. In [53] Eugene Famaand Marshall Blume achieved similar conclusions,19whichin 1970 led Eugene Fama [50] to dismiss technical analysisas a futile activity.In 1967, in spite of the tendency to reject technical analy-sis, M. F. M. Osborne [123] found that applicability of therandom walk theory and technical analysis can be depen-dent on the underlying time frequency of prices. He con-19They conducted a study of the thirty Dow Jones Industrial Stocks us-ing 24 different lter rules, ranging in size from 0.5% to 50% for the timeperiod from 1957 to 1962. They concluded that the lter rules were notpro table when the effect of interim dividends and brokerage commissionswere considered [53].
  10. 10. cluded that in general shorter intervals (daily, weekly) tendto show more "non-random walk" properties than longer in-tervals (monthly).After Eugene Fama silenced empirical studies of techni-cal analysis for almost twenty years, in the second half ofthe 1980s the interest of academic community returned tothe topic. New empirical studies either found evidence infavor of technical analysis20or de ned segments and mar-kets, where the weak form of market ef ciency prevails andtechnical analysis brings a small added value21.The return and price predictability is of interest not onlyin stock markets, but also in the currency markets domi-nated by professional investors [5, 151].22Blake LeBaron[93] showed that simple rules used by technical traders havesome predictive value for the future movement of foreignexchange rates. He explained that the reason can be in thenature of foreign exchange markets, where there are sev-eral major players whose objectives may differ greatly fromthose of maximizing economic agents. The results of hisstudy showed that this predictability was greatly reduced,if not eliminated, on the days in which the Federal Reservewas actively intervening were removed.23Along with empirical support technical analysis also re-ceived more interest by the theory of nancial markets.A typical example is a study of Avraham Beja and BarryGoldman [17], where they showed that incorporating tech-nical analysis could help to explain empirical propertiesof nancial markets. David Brown and Robert Jennings[27] constructed a two-period dynamic equilibrium modelto demonstrate that rational investors should use historicalprices in forming their demands.Arthur et al. [9] created a model, populated with arti cialtechnical analysts, known as Santa Fe arti cial stock mar-ket (ASM). The model allowed the authors to explain thecontradiction between the theoretical literature and practi-tioners view on market ef ciency. The simulation resultsshowed that both views were correct, but within differentregimes of the market. The market settled into the rational-expectations equilibrium of the ef cient market literaturewhen the ASM agents had enough time to accumulate andprocess information. Otherwise, if in a hurry to accumulateand process market information investors did place moreweight on technical trading. As a result, the market dom-inated by technical trading experienced temporary bubblesand crashes.William Clyde and Carol Osler [34] provided theoreti-cal foundations for technical analysis as a method for do-ing nonlinear forecasting in high dimension systems. They20For examples see [1, 6, 8, 25, 27, 41, 58, 74, 87, 91, 101, 102, 108,110, 112, 119, 128, 134, 138, 144, 146, 147, 152].21For examples see [14, 40, 57, 59, 104, 112, 122, 128, 134, 138].22For examples see [19, 63, 99, 103, 116, 122, 124, 148, 149, 150].23A similar topic is discussed by Christopher Neely [118].argued that traditional graphical technical modeling meth-ods might be viewed as an equivalent to nonlinear meth-ods that use the Taken method of phase space reconstruc-tion combined with local polynomial mapping techniquesfor nonlinear forecasting. The study presented evidence insupport of this hypothesis in the form of an application ofthe head-and-shoulders formation identi cation algorithmto high-dimension nonlinear data, resulting in successfulpattern identi cation and prediction.Alexandra Ilinskaia and Kiril Ilinski [90] used the frame-work of Gauge Theory of Arbitrage to show that techni-cal analysis and market ef ciency corresponded to differenttime regimens. From their point of view, technical predic-tions exist due to an internal deterministic dynamics, whichbrings the market to an equilibrium. They showed that tech-nical analysis indicators and their predictions existed forshort time horizons while for long time horizons the modelproduced an EMH state with realistic statistical behavior.24Alan Morrison and Nir Vulkan [113] studied a version ofthe standard Kyle [89] model with endogenous informationacquisition. They found that there was a robust equilibrium,which allowed free entry and in which speculators attainedpositive pro ts.Based on this, one might argue that individual investorsare aware of short-term nancial market returns and pricepredictability and try to exploit the trading opportunities byusing technical analysis.5. Arti cial Technical AnalystPrevious sections have emphasized two competing para-digms in nance: the ef cient market hypothesis and thelegacy of technical analysis. The overview of empiricaltests did not reveal a clear dominance of one paradigm oranother. The main reason of this ambiguity is the jointhypothesis problem, which constrains tests of market ef -ciency. To overcome this limitation one needs to design amodel-free test. Spyros Skouras [143] proposed a solution,which allows to test market ef ciency independently of anequilibrium model, - his arti cial technical analysts. Hisconcept of the ATA will be used to design our arti cial tech-nical analyst, which will incorporate latest advances in arti-cial intelligence, pattern recognition and data preprocess-ing. This section outlines key components of a new imple-mentation of the ATA.A blueprint of the ATA has three major components: datapreprocessing, pattern recognition and decision-makingmechanisms.The rst part of data preprocessing is a homogenizationmechanism. Since the idea of technical analysis is the inter-pretation of past nancial data, its quality and consistency24The investors aware of this fact might increase the trading frequencyto exploit these opportunities.
  11. 11. crucially depends on the quality of data. Two aspects ofdata preprocessing will be taken into account. The rst oneis a reduction of problem complexity. And the second oneis a maximization of the informational content of the data.Both aspects can be resolved through the mechanism of datahomogenization.The second part of data preprocessing is a piecewiselinear approximation (PLA) mechanism. This mechanismserves to identify important peaks and troughs in time se-ries of prices. Since the ATA should have good pro ciencyin detecting peaks and troughs the quality of piece wise ap-proximation has a crucial role.The second component in the ATA is responsible for pat-tern recognition. It will use peaks and troughs, identi ed bythe PLA, to learn patterns in the data. The pattern recog-nition of the ATA is similar in a sense to the candlesticktechnique. Like with the candlestick patterns actual valuesof prices have no importance, but their relative values. Inaddition, the ATA will incorporate relative waiting time ofappearance of each price observation. This approach willallow to see which patterns can predict price behavior.The cognitive mechanism of the ATA is based on arti-cial intelligence. Since learning classi er systems (LCS)are one of few implementations of arti cial intelligence thathave a transparent structure of solutions they will be usedfor building the cognitive mechanism. There are many im-plementations of LCS, but all of them are dominated by theXCS, developed by Stewart Wilson [159, 160]. Unfortu-nately, the XCS does not have the power to solve our prob-lem within reasonable time. To overcome this limitation anew implementation of LCS will be used - the true classi ersystem (TiCS), - developed by Timur Yusupov.Finally, using the concept of revealed transaction costs adecision-making function will be introduced.This section is organized as follows. First, Subsection5.1 presents the data preprocessing component. It is fol-lowed by Subsection 5.2, which outlines the implementa-tion of arti cial intelligence, the TiCS. Subsection 5.3 in-troduces the pattern encoding mechanism. In Subsection5.4 revealed transaction costs and decision making are pre-sented. A discussion concludes the section.5.1. Data PreprocessingThis subsection deals with the preprocessing of the data.With the data coming in raw, tick-by-tick form one hasto apply some homogenization procedure to reduce the dataand the problem complexity. There are two methods of ho-mogenization. That is previous- and linear-tick interpola-tion. Empirical literature does not indicate any pronounceddifference in the results produced by either method [39].Due to simplicity and fast computability the previous-tickinterpolation is selected.The drawback of homogenization is inef cient use ofdata. High-frequency data has much more observations thanis required for some xed frequency of homogenization. Atthe same time the ATA needs as much data as possible forfast learning. One way to "feed" the ATA and to improvethe ef ciency of data processing is to use sequential roottime shift in the homogenization procedure. This allows toachieve almost 100 percent ef ciency of data utilization.One important aspect of homogenization is the necessityto exogenously specify the optimal frequency. The criterionof optimality is pro tability. To get the sign and the magni-tude of the pro t one has to consider transaction costs (TC).With no knowledge of TC the notion of revealed transactioncosts can shed light on hypothetical pro ts.25Aggregate re-turns adjusted for a schedule of transaction costs, as a di-rect indicator of pro tability, should be computed for a gridof frequencies of homogenization. The maximum value ofbreakeven revealed transaction costs will indicate the opti-mal frequency of homogenization.Another related aspect of data preprocessing is selectionof the optimal subsample size. For consistent application oftechnical trading rules the ATA should have a well de nedand xed subsample of recent observations. Like in the pre-vious case the grid analysis and revealed TC should be usedfor the search.To sum up, without any exogenous information on thefrequency of homogenization, the value of transaction costsor optimal subsample size one needs to perform parallelsearch along all three variables, which results in a three-dimensional search problem. The optimal value of the sub-sample size, or the frequency of homogenization can varyacross stocks, markets and through the time. As a result,wrong selection of these parameters can destine the ATAperformance to be very low from the very beginning.The PLA is an important ingredient of the ATA.26With-out this mechanism the system is insensitive to turningpoints in time series. The segmentation algorithm is an ef-fective way to perform identify these points. For this thePLA constructs a representation of the original time seriesby several linear segments. Assuming the ends of linearsegments are connected, one can use those joints as identi -cation points of the underlying time series. These identi ca-tion points will be used for similarity search and subsequentforecasting of the next observation in the time series.Depending on speed or accuracy needed one can pick themost appropriate algorithm out of possible alternatives.2725For details on revealed transaction costs see Subsection 5.4.26The formal de nition of the piecewise linear approximation is an ap-proximation of a time series of the length n by k linear segments. Nor-mally, one chooses k to be much smaller than n, which makes the storage,transmission and computation of the data more ef cient [83]. The abbrevi-ation of the piecewise linear approximation is PLA. One can refer to it assegmentation algorithm or approach.27For an overview of PLAs see [83].
  12. 12. Since the Top-Down algorithm28takes a constant time, andhas acceptable degree of accuracy it is chosen for applica-tion in the ATA.5.2. Learning Classi er Systems: TiCSThe arti cial technical analyst is designed to replicatethe professional expertise of a technical analyst. The qual-ity of an analysis crucially depends on the cognitive abil-ity of the ATA. Imitation of human-like cognition is a verycumbersome task, since one needs to match the abilities ofthe human brain. The sophistication of the human brainallows it to instantaneously process incoming information,to associate it with past experience, and to make sensibleprognoses. As a result we are able to learn from our experi-ence and to generalize it to new, unseen situations. With thehelp of Arti cial Intelligence (AI) the ATA should be ableto replicate the process of human-like cognition.In the subclass of AI - Machine Learning, learning clas-si er systems (LCS) are algorithms meant to imitate the hu-man ability for classi cation, learning and generalization.The Encyclopedia Britannica de nes these abilities as fol-lows. Classi cation is the ability to systematically arrangein groups or categories according to established criteria.Learning is the ability to adapt to the environment and toalternate behavior as a result of individual experience. Andgeneralization is the ability to respond in the same wayto different but similar environmental conditions. To meetthese criteria, LCS should possess the following character-istics.(i) the ability for on-line classi cation and establishingthe patterns of the different environmental situations.(ii) the ability to distinguish and preserve the most persis-tent patterns.(iii) the ability to ignore any irrelevant or noise informa-tion.The LCS were rst introduced by J. Holland [70, 71].29LCS were designed to read the current environment at statein terms of a xed number of predetermined conditions andto provide the most adequate mapping into the space of28In the Top-Down algorithm a time series is recursively partitioned un-til some stopping criteria. The rst approximation is one line, which con-nects the rst and the last point in the original time series. To nd a betterapproximation one evaluates every possible partitioning of the previousapproximation. The partitioning which provides the best goodness of tlocates next split. Newly segmented approximation is reexamined for anew partitioning and the process repeats. The algorithm runs until eithera benchmark goodness of t is reached, or an approximation gets enoughlinear segments.29For the introduction to LCS see [65, 109], for a recent surveys on itsapplications and development see [92].coming events. For this purpose LCS employ Genetic Algo-rithms (GA) during the training period to identify a correctmapping from the combination of predetermined conditionsto the most probable event. In the process, LCS should iden-tify irrelevant conditions from noise and distinguish persis-tent combinations of conditions.In the seminal work of J. Holland and in the related lit-erature of the following decades the adequacy of each clas-si er was measured by the predetermined criteria, knownas strength or tness. This parameter was serving both as apredictor of future payoff and as the classi ers tness forthe genetic reproduction. Unfortunately, this primitive ag-gregation resulted in low performance of LCS. As a result,the considerable enthusiasm of the 1980s declined in theearly 1990s. LCS seemed too complicated to be studied,with only few successful applications reported. In the mid1990s the eld appeared almost at dead end [72].In response to this situation Wilson [159] introduced theXCS. The primary distinguishing feature of the XCS is thatclassi er tness is based on the accuracy of classi er payoffprediction rather than on payoff prediction (strength) itself.Although the XCS is currently a favorite, it has somedisadvantages. Its overcomplicated structure slows downthe algorithm in nding solutions. The XCS originatesfrom a "zeros level" classi er system, which was intendedto simplify Hollands canonical framework while retainingthe essence of the classi er system idea [159]. At some stepthe intention to simplify turned out to overcomplicate. Toillustrate this point [29, 28] list at least 28 parameters andswitches, which need to be speci ed. Their numerosity andvague explanation in the source literature30makes tuning ofXCS an art rather than a precise science. These parametersare claimed to change the XCSs behavior, adjust it to thecurrent problem and specify output characteristics [29]. Un-fortunately, low transparency of the algorithm and a lack oftheoretical studies make re-speci cation of the parametersof the XCS impossible.31As a result the XCS shows highinertia in learning relatively simple problems. To overcomethose limitations a new classi er system was introduced -the True Classi er System (TiCS).The key element of the TiCS is the Micro-Genetic Al-gorithm ( GA)32. Unlike conventional algorithms the GArequires speci cation of only 2 parameters. The same 2 pa-rameters are used for the TiCS activation and run. The rstparameter Ng de nes the global population size of classi-ers. The second parameter Ns instructs the algorithm onhow many classi ers should match the input signal to formthe sub-population.30There are only few articles were some of this parameters are studiedin detail. The best description is provided by [29, 28].31For this reason the comparative study uses the default parameters ofthe XCS.32For details on the GA see [88].
  13. 13. Figure 1. TiCS and its environmentFigure 1 outlines the operation of the TiCS. It followsthe original idea of Hollands LCS. From a dynamic envi-ronment the TiCS extracts static sub-problems to providean adequate response. For this purpose an input signal ismatched against the condition part of each classi er. Thematched classi ers form a current sub-population. Eachclassi er in the population should be as general as possible,i.e. it should correctly respond to the maximum number ofstates. A matched classi er is assumed to have the correctresponse. Given the goal of generalization, the measure oftness is the quantity of "dont care" symbols in the condi-tion part. This allows to rank the classi ers. If the numberof matched classi ers is more than Ns, the classi ers withthe lowest tness are excluded from this sub-population.The classi ers in the sub-population are referred to asSoldiers, since they are too Specialized. The best in tnessclassi er is referred to as a General, since it achieved themost General level without failing. The General forms theTiCS response to the input signal. Meanwhile, the classi-ers in the sub-population share the "experience" throughthe GA. The probability of being selected is proportionalto tness. Selected classi ers crossover their condition andaction parts to form a new sub-population. The Generalenters the new sub-population only if his response was ad-equate. The new sub-population then replaces the currentsub-population in the global population.In case there is not a suf cient number of classi ers inthe sub-population a covering mechanism lls missing posi-tions. Covering creates classi ers that match a current inputsignal by copying it to the condition part of new classi ersand replacing some condition bits with "dont care" symbol#. The corresponding actions are randomly generated.5.3. Pattern Encoding MechanismSince the TiCS is intended to be used for pattern recog-nition in time series it requires a particular encoding mech-anism. This mechanism allows to encode time series intostrings of conditional bits.At the rst step a subsample of the time series is de-meaned and normalized to have unit variance. This allowsto recognize similar patterns irrespective of the current levelor the variance. Next, the PLA algorithm identi es posi-tions of key points describing the subsample of time series.
  14. 14. Each key point connects linear approximations found byPLA. With n prede ned linear segments there are n + 1key points.Application of demeaning and normalization allows todescribe the position of each key point within the same two-dimensional coordinate space. An ordinate dimension cor-responds to the level in time series and is constrained tothe interval [ 2; 2]. A coordinate dimension corresponds totime stamps of time series and is constrained by the interval[1; L], where L is the length of the subsample.At the second step the encoding takes place. First, twoequal segments of a coordinate and ordinate space are de-ned. In the beginning they are [ 2; 0) and [0; 2] for thecoordinate axe, and [1; L=2) and [L=2; L] for the ordinateaxe. Next a coordinate (ordinate) of a key point is assignedto one of the two segments. If it belongs to the below (left)segment of the coordinate (ordinate) then the rst conditionbit is assumed to be 1, otherwise it is assumed to be 0. Nextthe segment, where the key point is located is divided intotwo new equal size segments. And again, the key point isassigned to one of the two segments and the correspondingbit is added to the condition bit-string. After a prede nednumber of iterations the coordinate (ordinate) position ofthe key point is encoded by a sequence of zeros and ones.Example 1: One needs to encode a position of a key pointfrom a demeaned and normalized subsample of 50 observa-tions. The level of the key point is 1:17, and the time stampis 11. Table 1 provides the results for encoding the rst 5bits. After performing iterative process the level is encodedas 11000, and the time stamp is encoded as 00111.The encoding mechanism allows decoding of a conditionbit-string to get the coordinate and ordinate limits. Since theTiCS has in the alphabet of condition bits the "dont care"symbol #, during decoding the process stops either when allbits are processed or when the rst symbol # is found. Thelatter case allows the TiCS to have varying interval withinwhich key points should be.Example 2: Using the same settings as in the previousexample one needs to decode bit-strings of coordinates andordinates: 010## and 11010, respectively. Table 2 pro-vides the results for decoding these bit-strings. After de-coding the level is found to be within [0:500; 1:000), andthe time stamp is decoded to be within [07; 09).5.4. Revealed Transaction Costs and Deci-sion MakingLong and short selling are the most basic transactions innancial markets. Any complex arbitrage strategy is justtheir combination. The applicability of either transactionnormally depends on the expectation about the future pricemovement and transaction costs. Wrong assessment of ei-ther of them can cause a nancial loss. With endogenousStep Ordinate segment Ordinate## Left Right bits1. [01; 25) [25; 50] 1____2. [01; 12) [12; 25) _1___3. [01; 06) [06; 12) __0__4. [06; 09) [09; 12) ___0_5. [09; 10) [10; 12) ____0Final ordinate bit-string: 11000Step Coordinate segment Coordinate## Low Up bits6. [ 2:00; 0:000) [0:000; 2:000] 0____7. [0:000; 1:000) [1:000; 2:000] _0___8. [1:000; 1:500) [1:500; 2:000] __1__9. [1:000; 1:250) [1:250; 1:500) ___1_10. [1:000; 1:125) [1:125; 1:250) ____1Final coordinate bit-string: 00111Table 1. Illustation of pattern-to-bits encodingmechanismA subsample of time series has 50 observation (ordinate axe). Values aredemeaned and normalized. Encoding of a key point with the level of 1:17and the position of 11. Asterisk denotes that the position is within themarked segment.price expectations one can evaluate maximum transactionscosts at which arbitrage strategies generate positive pro ts.Transaction costs include commissions paid per transac-tion, internal R&D expenses, a bid-ask spread and the im-pact on price. Every component complicates measuring ac-tual transaction costs. If, for example, there is only a timeseries of past prices, then the bid-ask spread, past commis-sions and the impact on price have to be estimated from thedata. Roll [135] introduced an implicit measure of effec-tive bid-ask spread that can be estimated from the univariatetime series. Lesmond et al. [96] used time series observa-tions of zero returns to estimate transaction costs of a mar-ginal investor.33Unfortunately, for the precise estimationof transaction costs one needs a complete data set to cap-ture all the components, which are usually not accessible intime or have con dential nature.Known transaction costs enable one to reveal the returnsuf cient to insure a positive pro t. If, for some reason,the exact value of transaction costs is not known, a reversesolution can be found, i.e. one can nd transaction costs thatinsure non-negative pro ts. Those costs can be derived fromthe arbitrage strategies mentioned above and are referred toas revealed transaction costs. Bessembinder et al. [20] useda similar concept, known as breakeven costs. In relation toour de nition the breakeven transaction costs are maximum33For the latest review of literature on transaction costs see [97].
  15. 15. Step Ordinate Ordinate segment## bit-string Left Right1. 1____ [01; 25) [25; 50]2. _1___ [01; 12) [12; 25)3. __0__ [01; 06) [06; 12)4. ___1_ [06; 09) [09; 12)5. ____0 [06; 07) [07; 09)Final ordinate interval: [07; 09)Step Coordinate Coordinate segment## bit-string Low Up6. 0____ [ 2:00; 0:000) [0:000; 2:000]7. _1___ [0:000; 1:000) [1:000; 2:000]8. __0__ [0:000; 0:500) [0:500; 1:000)9. ___#_10. ____#Final coordinate interval: [0:500; 1:000)Table 2. Illustation of bits-to-pattern decodingmechanismA subsample of time series has 50 observation (ordinate axe). Values aredemeaned and normalized. Decoding of coordinate bit-string 010##, andordinate bit-string 11010. Asterisk denotes selected segment.costs that insure zero pro t.Following the differentiation of strategies, one can de-rive revealed transaction costs for the case of expected in-crease and decrease in the assets price. Given the high-frequency nature of data and transactions, one can neglectinterest rates as well as the in uence of dividends and splits.For the case of expected price increase the value of re-vealed transaction costs, bcLt , is derived from long position,and should satisfy the following inequality to insure a posi-tive pro t:c <E [pt+1] ptE [pt+1] + ptbcLt ; (1)where c is actual transaction costs, pt is the current pricelevel, and E [pt+1] is expected next period price. For theshort position the value of revealed transaction costs, bcSt ,should satisfy the following inequality to insure positivepro t:c <pt E [pt+1]E [pt+1] + ptbcSt : (2)A combination of both cases allows to formulate adecision-making function, which takes as arguments ex-pected and current price, and the value of anticipated trans-action costs:Dt (c; pt; E [pt+1]) =8>>>><>>>>:B if c <E [pt+1] ptE [pt+1] + pt;S if c <pt E [pt+1]E [pt+1] + pt;N otherwise,(3)where B denotes a decision to buy, S - a decision to short-sell and N - to do nothing.6. Tokyo Stock Exchange: Market Microstruc-ture and Data DescriptionThis section describes the data used in this paper. Thedata cover historical stock prices collected on the TokyoStock Exchange (TSE).The TSE is a classical example of an order-driven mar-ket. It operates as a continuos auction, where buy and sellorders interact directly with one another. The study of theorder-driven activity of the TSE did not show signi cant dif-ferences from the New York Stock Exchange or from stocksmarkets with designated market-makers [7, 15, 95]. At thesame time the TSE market has some speci c features, whichcan have an impact on empirical results. Since the results ofempirical analysis can be sensitive to the method of data se-lection, the section describes our method of data selection,which minimizes the impact of selection bias on empiricalresults.The TSE has no market-makers. All orders, whetherlimit or market orders, are placed by broker/dealer tradingparticipants and matched in accordance with price prior-ity and time priority rules. Under the price priority rule, asell (buy) order with the lowest (highest) price takes prece-dence. Under the time priority rule, an earlier order takesprecedence over others at the same price. Thus, when thelowest sell and highest buy orders match in price, the trans-action is executed at the price.34At the TSE there are two transaction methods: theitayose and zaraba. The itayose method is used mainly todetermine opening and closing prices. Under the itayosemethod, the time priority rule is not applied and numerousorders placed before price setting are matched in aggregate.In contrast, under the zaraba method, both the price priorityand time priority rules are applied, and pairs of buy and sellorders are matched continuously.The TSE adopts several measures to prevent wild short-term uctuations in prices: special bid and ask quotes, dailyprice limits, trading units and margin transactions.35Thesemeasures do not only help ensure price continuity, but alsoin effect work as "circuit breakers" in an emergency. In34For more details and speci c parameters see the source [155].35For their details see [155].
  16. 16. addition the TSE uses off-auction trading to handle largeblock orders. The off-auction trading system allows to ac-commodate large block orders and basket order transac-tions, the trading of which is dif cult under the competitivetrading scheme of auctions. To eliminates the risk of tradecounterparty default the TSE utilizes the central counter-party system and the clearing participant system for thesettlement of trading on its exchange. Settlement for nor-mal domestic equity transactions in the exchange market ismade on the fourth business day starting from the transac-tion date (T + 3).The TSE has three trading sessions per day: from 8:20till 9:00, from 11:00 till 12:30 and from 15:00 till 16:30.For half-trading days only the rst two sessions take place.The total trading time sums up to 240 minutes over the 490minutes between the opening and closing time.The empirical part of the paper studies the data collectedon the TSE. Data comes in a raw, tick-by-tick form, andincludes mid-prices and volumes of each transaction. Theprecision of time stamps is one minute. The dataset cov-ers 2273 stocks traded at the TSE during a period from11/03/1996 till 22/06/1998, i.e. 833 trading days.Due to computational limitations three subsets of timeseries were selected for the empirical study. Under theassumption that the return (or price) predictability and,correspondingly, investors attitude might be different fordifferent levels of liquidity the dataset was divided intothree groups based on the liquidity level of the underly-ing stocks.36Each subset was randomly (with withdrawing)populated by 9 time series, which belong to stocks with thesame level of liquidity. For each group of liquidity the me-dian stocks provided the tenth time series, thus creating ahigh-, medium and low-liquidity pool of time series.Table 3 lists selected stocks and provides statistical prop-erties of their time series. Statistical properties are obtainedfor daily data over the time period covered in the study. Ashort description of the occupational activity of underlyingcompanies accompanies each record. The stock that repre-sents the median in liquidity is marked by the asterisk nextto a company name. Statistical properties cover mean ( ),sample variance ( ) and sample slope ( ).Figure 2 presents equally weighted indexes for each liq-uidity pool of TSE stocks (thick line). Prior to aggregationeach constituent time series was rebased by setting its rstobservation in the series equal to unity (thin lines).7. Application of the ATA to The Tokyo StockExchange DataTechnical analysis, i.e. detection of patterns in time se-ries of prices, is a direct contradiction to the weak form of36The criterion of liquidity is the number of trades over the covered timeperiod.Company Statistics of price seriesname (sektor code)1. High-liquidity poolSumitomo Marine 814:98 90:26 0:27& Fire Insurance (1)Nisshin Steel (2) 288:24 97:34 0:54Kenwood (3) 524:83 122:22 0:59Daihatsu Motor (4) 613:29 71:99 0:32Melco (5) 3053:31 917:88 4:39Ricoh (5) 1386:98 211:53 0:82Hitachi (6) 1056:57 107:76 0:13Kirin Brewery (7) 1140:67 119:82 0:38Matsushita Elec. 1992:27 178:00 0:57Industrial (3)Adeka* (8) 772:51 164:61 0:872. Medium-liquidity poolHoko Fishing (9) 245:24 112:93 0:61Chinon Industries (10) 857:62 480:91 2:62Tokyo Style (11) 1517:73 239:48 1:23Miraca Holdings (12) 710:59 212:03 1:10CO-OP Chem. (8) 256:82 123:70 0:70Canon Electr. (5) 818:12 81:70 0:00Tokyo Cosmos 326:55 110:50 0:59Electric (6)Chunkyo 1054:55 114:99 0:46Coca-Cola (7)Hitachi Medical (13) 1569:24 196:23 0:86Aichi Tokei 458:38 171:07 0:96Denki* (6)3. Low-liquidity poolTonichi Carlife GP (14) 503:26 164:28 0:86Sonton Food Ind. (9) 1296:90 146:96 0:72Tensho Elec. Ind. (10) 352:64 120:43 0:60CFS (15) 1121:76 253:27 1:42Tokyo Auto 472:81 156:88 0:86Machine Works (10)Smbc Friend Sec. (16) 295:27 146:52 0:80Lohmeyer (9) 269:37 109:71 0:60Daiwa Heavy Ind. (10) 278:31 110:56 0:61JSP (8) 1021:06 207:80 1:07Unozawa-Gumi 426:58 118:27 0:56Iron Works* (10)Table 3. List and description of stocks usedin the empirical studyThe table uses the following sector codes:(1) - Nonlife Insurance; (2) - Industrial Metals; (3) - Leisure Goods; (4)- Automobiles & Parts; (5) - Technological Hardware & Equipment; (6) -Electrical, Electronic Equipment; (7) - Beverages; (8) - Chemicals; (9) -Food Producers; (10) - Industrial Engineering; (11) - Personal Goods; (12)- Pharmacology, Biotechnology; (13) - Health Equipment & Services; (14)- General Retailers; (15) - Food & Drug Retailers; (16) - General Financial.
  17. 17. Figure 2. Equally weighted indexes for liquid-ity pools of TSE stocksthe EMH. This hypothesis is a corner stone of most theoriesof nancial markets. The EMH postulates that in weakly ef-cient nancial markets it is impossible to pro t by predict-ing next periods price used on time series of past prices orreturns. The contradiction turns technical analysis into an"outlaw" of nancial theory separating the nancial com-munity into two camps: the camp of academics, who ad-vocate the EMH; and the camp of practitioners, who keepusing technical analysis.The overview of practices in nancial industry showsthat many investors, including professional traders and an-alysts, are widely using technical analysis [5]. Previous in-vestigations demonstrate that under some conditions techni-cal analysis can provide substantial returns. Unfortunately,the ndings are undermined by two limitations. Techni-cal analysis is a complex method, which includes rigorousmathematical formulas as well as abstract visual patterns oftime series. As a result, researches use only a fraction of themethodology, which dramatically constrains the potential oftechnical analysis. On the other hand, when the ability of anexpert, who is knowledgeable of and uent in all aspects oftechnical analysis, is studied one cannot distinguish whetherthe results are solely due to technical analysis or a subjec-tive interference of an analyst.The ATA overcomes these drawbacks. The ATA is a ro-bust implementation of the technical analysts expertise. Itfollows the aim of technical analysis to detect patterns inprice time series. The cognitive mechanism of the ATA, theTiCS, uses the methodology of technical analysis to gen-erate online forecasts of next periods price in a dynamicenvironment. To insure the robustness and effectiveness ofgenerated forecasts the ATA performs a sequence of datapreprocessing steps. Investment decisions are generated toobtain aggregated returns adjusted for transaction costs.In the process of calculation several assumptions aremade. First, the impact of in ation, dividends and splits isdisregarded, since at high frequency their impact is negligi-ble. Second, the aggregate return is computed separately forevery time series in the study. Third, trading strategies areapplied at every period, i.e. at the beginning of each periodthe previous position should be closed. Correspondingly theaggregate return is a product of returns in all time periods.And nally, the decision-making process and calculation ofreturns take into account round-trip TC.7.1. Decision-Making Function and Its In-formational BaseThis section presents the decision-making functions andits informational base.The informational base of the decision-making processincludes two components. The rst component are expectedtransaction costs. Transaction costs have a direct in uenceon trading decisions, since the value of extracted returnshould be suf cient to cover round-trip transaction costs andwith a stochastic return distribution the probability of trad-ing is higher under small transaction costs than under hightransaction costs. Due to its hypothetical nature this empir-ical study uses a set of discrete values of transaction coststaken in a grid from an interval [0; 2] of percent of transac-tion value with an increment of 0:001 percent.The second component of the informational base is asubsample of recent prices observations. Technical analy-sis requires this subsample for forecasting the next periodsprice. Speci cally to the ATA, it requires speci cation ofthe subsample size. The ATA is able to identify relevantprice observations and lter out the rest. But, in case sub-samples are too small or too big, the ATA does not haveenough price observations to compute forecasts or, respec-tively, it would take more time to detect the pattern than theduration of this pattern in the market. To cover this aspectthe study uses a set of discrete subsample sizes taken in agrid from an interval [50; 250] of price observations with anincrement of 10 observations.Along with the two explicit components of the informa-tional base for a decision there is a third component - thefrequency of decision making. It has an implicit in uenceon outcomes of decision making. A low frequency allowstraders to avoid frequent expenses on transaction costs. Atthe same time, in a volatile market it constrains traders totake a speculative advantage from local trends. The studyuses a set of discrete frequencies in a grid within the inter-val [1; 10] of minutes with an increment of one minute.
  18. 18. In general, the process of decision-making is formalizedthrough a function D (), which maps the arguments into thespace of trading actions:D (c; pt; pt 1; :::; pt n) = fB; S; Ng ; (4)where c stands for transaction costs expressed in fractionsof transaction value; fpt; pt 1; :::; pt ng are current andlagged asset prices; B denotes the buy transaction; S de-notes short-selling; and N means to remain inactive.Normally, the decision-making process includes twosteps: forecasting of next periods price and maximiza-tion of a next period return adjusted for transaction costs.Forecasting is speci c for each strategy since in everycase there will be speci c forecast mechanism. In gen-eral forecasting provides an estimate of the next pe-riod asset price conditional on the informational base,E [pt+1j fpt; pt 1; :::; pt ng]. The second step, return max-imization, performs a search through the outcomes of pos-sible trading actions to nd the highest return. This step isbased on the notion of the revealed transaction cost. Thus,the general form of the decision-making functions is equa-tion (3) with expectations E [pt+1] been conditioned on pastprices pt; pt 1; ::: that enter the TiCSs pattern recognitionalgorithm.Unlike the conventional forecast methods the ATA per-forms interval price forecasts. This allows to convey theforecast of price developments and the ATA con dence inthose forecasts.37The con dence is indicated by the differ-ence between the upper and lower limits of the forecast. Ahigh con dence is re ected in a small difference, while alow con dence is conveyed through a high difference. Thesmallest difference is de ned to be one basic point in themarket. The highest difference is in nity.The ATA uses technical analysis to obtain the intervalforecast, which is constrained by the upper and lower lim-its: pt+1 and, respectively, pt+1.38Once the interval is de-ned one of the three possible trading actions is selected tomaximize a current return. This is formalized in the ATAdecision-making function:Dt (c; pt; pt 1; :::; pt n) =8>>>><>>>>:B if c <pt+1ptpt+1+ pt;S if c >pt pt+1pt + pt+1;N if otherwise.(5)37The ATA does not distinguish whether a low con dence is only dueto a lack of experience in a new situation or/and due to a presence of riskassociated with an underlying asset, since either case leads to uncertainty.38These limits are the decoded action suggested by the TiCS. Since theATA operates with homogenized data only the limits of levels (in this caseprices) are returned. In the future, the ATA can be extended to work withirregularly spaced time series. In this case the forecast of the ATA willinclude additionally the time interval within which the next level is pre-dicted.The aggregate return adjusted for transaction costs is cal-culated as:R =TYt=1rt; (6)where the time is de ned on the interval from 0 to T. Thereturn in each time period, rt, is calculated as:rt (:::) =8>>><>>>:pt (pt 1 + pt) cpt 1if Dt 1 = B;pt 1 (pt 1 + pt) cptif Dt 1 = S;1 if Dt 1 = N:(7)8. Performance of ATA Trading StrategyFigures 3 - 5 present the results of hypothetical appli-cation of the ATA trading strategy on the TSE data. Therst column of each gure shows breakeven separation sur-faces. Columns 2 - 3 display the slice views correspondingto the rst column. Each row represents the time span overwhich the returns are aggregated. The separation surfaceshows at which transaction costs and at which combinationof trade frequency and subsample size the application ofthe ATA trading strategy is breakeven. Any point above thesurface indicates a loss, while any point below is a gain. Onthe slice view fat dots show breakeven transaction costs ateither xed subsample size (column 2) or trade frequency(column 3). Color notation distinguishes the magnitude ofgains (in shades of red) or losses (in shades of blue).Table 4 presents the summary of the gures. It lists themaximum breakeven transaction costs obtained for threegroups of stock liquidity. Each value of breakeven trans-action costs is accompanied by the frequency of trading andthe subsample size at which it was observed.The rst conclusion is that the ATA can successfully ap-ply technical analysis to extract positive returns adjusted fortransaction costs. The best performance is achieved at atrading frequency of 4 minutes, the subsample size of 50observations, with the medium liquidity stocks. Here the re-vealed transaction costs are 0:32 percent of the transactionvalue. If under these settings the actual transaction costswould be strictly less than 0.32 percent of the transactionvalue, then a technical analyst would perceive this marketsegment at that time as weak-form inef cient.The analysis of speci c time spans reveals that the val-ues of maximum breakeven transaction costs are increasingthrough time horizons.39This observation is valid for allliquidity pools. There are two possible explanations. The39That is in the rst time span the value of maximum breakeven trans-action costs is less than in the second one, and in the second time span thevalue is less than in the third time span.
  19. 19. Figure 3. Application of ATA trading strategies on the pool of high liquidity stocksrst one is that the data have different structure in each timespan, which, in relation to the ATA forecasting, translatesinto a different degree of predictability and different distri-bution of returns in each time span. The second explanationis a learning ability of the ATA. That is if the distribution ofprices and the degree of predictability is the same for eachtime span, then the increase in the maximum breakeventransaction costs is due to the ATA learning.To test the validity of the rst explanation the histogramand empirical CDF of returns were produced for each timespan and liquidity pool. The analysis of returns instead ofraw prices allows to avoid the problem of comparing timeseries with different levels of prices.40Figure 6 presents thehistograms and empirical CDF of returns. Columns fromleft to right correspond to high-, medium- and low-liquidity40Returns are unit-free, which makes them easy to compare and aggre-gate.pools, respectively. Each panel shows the overlay of his-tograms and empirical CDF for all three time spans. Chartsshow that the distribution of returns are almost identical foreach time span.41The BDS test is applied to compare degrees of pre-dictability throughout all time spans.42Its advantage is thatit tests the null hypothesis of no dependence in the dataagainst any possible alternative. In this way the approachof the BDS test is similar to the ATA, which also looks forany possible dependence in the data. Since the ATA usesrolling subsamples of observations to perform forecasts the41Here and in the comparison of the BDS test statistic distributions indifferent time spans the analysis omits the results of the statistical tests.Even though the Kolmogorov-Smirnov test rejected the hypothesis of iden-tical distributions the high number of observations present in each sample(on average 27000 observations) the test would detect slightest differencebetween samples. Similar problems were observed with other nonparamet-ric tests, which were used to compare the distribution of samples.42For details on BDS test see [26, 81].
  20. 20. Figure 4. Application of ATA trading strategies on the pool of medium liquidity stockssame subsamples are used in the BDS test. The histogramsand empirical CDF of the BDS test statistics are presentedin the last two rows of Figure 6. In the high- as well as in themedium-liquidity pools the histograms and empirical CDFare identical for all time spans.The identity of the return distributions and degree of pre-dictability clearly supports the second explanation. The in-crease in the value of maximum breakeven transaction costsis indeed due to ATA learning (see Table 4).The conclusion is that the ATA is able to extract positivereturns adjusted for and conditional on transaction costs byprocessing past prices. The returns, proxied by the max-imum breakeven transaction costs, are increasing throughtime, which demonstrates the ability of the ATA to mastertechnical analysis.9. ConclusionsThe paper presented a study of market ef ciency fromthe viewpoint of arti cial technical analyst. The arti cialtechnical analyst had been designed to replicate the exper-tise of technical analysts in a robust and objective way. Itsapplication to the Tokyo Stock Exchange data under a vari-ety of transaction costs revealed that when transaction costswere suf ciently low the market could be perceived as in-ef cient and technical analysis could be rewarded with sub-stantial pro ts, while under higher transaction costs the per-ception of market ef ciency prevailed.The ef cient market hypothesis is one of the central ele-ments of nancial theory. Coined by Harry Roberts and for-malized be Eugene Fama it postulates the impossibility ofgaining pro t on the base of information contained in pastprices or returns of nancial securities. In spite of its promi-nent role in nancial theory empirical studies persistently

×