Technical Analysis of the Taiwanese Stock Market

We study the profitability of technical trading rules based on 9 popular technical indicators. To further examine whether investors can design technical trading strategies that can beat the buy-and-hold strategy, we establish 13 trading models based on one indicator, 25 models based on two indicators, and 28 models based on three indicators. The empirical results show that 58 out of 66 models reject the null hypothesis of equality of the mean returns between buy days and sell days. Our findings provide support for the predictive power of technical trading rules. Finally we employ Hansen’s (2005) Superior Predictive Ability to investigate data snooping problem. Overall we observe an inverse association between the number of technical indicator combinations and trading profitability.


Introduction
Technical analysis is based on the belief in which asset prices will move in trends.A technician does not consider much about fundamental factors such as supply and demand.He or she instead, in hopes of projecting future price movements, investigates historical price changes by examining charts, moving averages, patterns, and a wealth of indicators derived from open, high, low, and closing prices and volumes.In recent years, technical analysis has turned into a more rigor and sophisticated approach and a myriad of research on this field have been documented.Pring (1991, p.3), for instance, shows that technical analysis is "to identify a trend reversal at a relatively early stage and ride on that trend until the weight of evidence shows or proves that the trend has reversed".Such evidence is decided by analyzing statistics produced by market activities such as volume, open interest, past prices, price patterns, and many other indicators based on prices and volumes.To further define technical analysis, John Murphy (1999, p.1) provides "the study of market action, primarily through the use of charts, for the purpose of forecasting future prices".Market action comprises the information from price, volume, and the open interest.
There is no shortage in the literature studying the profitability of technical analysis.Empirical studies have evaluated technical trading rules for verifying efficient market hypotheses or finding profitability.For example, Taylor and Allen (1992) show the value of technical analysis for chief foreign exchange dealers.They report "There is also a skew towards reliance on technical, as opposed to fundamentalist, analysis at shorter horizons, which becomes steadily reversed as the length of horizon considered is increased.A very high proportion of chief dealers view technical and fundamental analysis as complementary forms of analysis and a substantial proportion suggest that technical advice may be self-fulfilling".Furthermore, Menkhoff and Taylor (2007) and Park and Irwin (2007) have provided a helpful review of the literature.Menkhoff and Taylor (2007) observe the effects of technical analysis on decision making of foreign exchange participants.They also suggest that, first, the phenomenon of market participants using technical analyses is not simply concluded as the world of irrationality.Second, government interventions are possibly associated with large changes of foreign exchange rates and they could affect the profitability of technical analysis.Third, order flows could also have an effect on the profitability of technical analysis.Lastly, technical analysis helps to reveal non-fundamental variables in the short term.Park and Irwin (2007) study more than 100 papers on technical trading up to 2004.Based on testing procedures, they divide the literature into two groups: (i) earlier studies up to 1988, and (ii) modern studies that start with Lukac et al. (1988) until the latest ones in 2004.In general, they observe that earlier studies support the hypothesis of profitability of technical analysis for foreign exchange markets and futures markets, but not for equity markets.They, however, suggest that modern studies also support predictive power of technical analysis for equity markets at least until the beginning of the 1990s.56 out of the 95 modern studies find support for profitability of technical trading rules, 20 introduce insignificant evidence, and the remaining 19 lead to diverse results.Moreover, they find that about half of the empirical studies have been finished in the 1995-2004 period.Such mode of renaissance is correlated to the publication of the three papers, Sweeney (1986), Lukac et al. (1988), and Brock et al. (1992).
More remarkable research since 2004 is introduced in chronological order.Mengoli (2004) reports valuable momentum trading approach for Italian stock market and suggests the importance of behavioral theory that could help in explaining technical trading profitability.Moreover, Fifield et al. (2005) examine 11 European stock markets by using some simple trading rules for the 1991-2000 period.They observe that the less developed markets are not informationally efficient, suggesting a degree of predictability in the price changes.Qi and Wu (2005) access the profitability of trading rules for seven currency markets and report that it is vague in that the profitability is produced by the consequence of data snooping or the structure of trading rules.Chang et al. (2006) employ moving average trading rules in Taiwan stock market and find profitability against buy-and-hold (B&H hereafter) strategy, even considering for transaction costs.Vasiliou et al. (2006) use moving averages and moving average convergence divergence rules for Athens stock market, and they provide strong support for the selected technical strategies.Loh (2007) compare technical trading rules used by academics (e.g.moving averages) with practitioner's approach (e.g.oscillators) for five Asian countries and documents that the projecting power of technical trading is improved as the practitioner's approach is collaborated with academics' rules.Lento et al (2007), in addition, apply Bolinger Band to Canadian and U.S. equity market and fail to support the profitability of technical analysis against B&H strategy when considering for transaction costs.Lento (2007) also examines the profitability of some selected technical trading rules against B&H strategy for eight Asian-Pacific stock markets, providing that profitability of technical trading rules appear in most markets except Nikkei and All Ordinaries Index.Balsara et al (2007) evaluate the profitability of moving average, channel breakout, and Bolinger Band and achieve significant abnormal returns after the inclusion of transaction costs for Class A (i.e.domestic) and Class B (i.e.foreign) shares listed on Shanghai and Shenzhen stock markets, China.Li and Wang (2007), likewise, employ moving average and trading breakout rules for Class A and B shares of China and document a support to the profitability of technical trading for Class B shares but not for Class A shares.After 2001, however, as domestic investors were permitted to trade B shares, the profitability for B-shares disappeared.McKenzie (2007) tests technical trading rules for 17 selected emerging markets and concludes that no trading rule can systematically produce considerable forecasting accuracy.Nevertheless, market conditions provide insights in the usefulness of trading rules.Savin et al (2007) investigate the price formation of Head-and-Shoulder (H&S) and conclude that the rule should be combined with a passive strategy in order to advance the performance.They also show that the passive strategy incorporated with H&S strategy can generate up to 8% excess return.Qi and Zhao (2008) employ moving average of Breath and Trin indicators in small and large stocks and report that the Breath indicator provides value in producing significant profits after considering for transaction costs for small stocks.Metghalchi et all (2008) study various moving average trading rules for Swedish stock market and suggest that technical trading can outperform B&H strategy even taking data snooping problem and transaction costs into account.Zhu and Zhou (2009) study the usefulness of moving average rules from the view of asset allocation by using the S&P 500 data from 1926 to 2004.They support that technical analysis is valuable for investment decisions.Metghalchi et al (2009), moreover, apply moving average rules in four Asian markets.They conclude that moving average rules have predictive power and can distinguish recurring-price patterns.Balsara et al (2009) conduct test for a group of U.S. stock indexes from 1990 to 2007.They document that moving average, trading breakout, and Bolinger Band rules underperform B&H strategy.However, significant positive returns can be produced by the opposing form of these three rules, after considering for a 0.5 percent one-way trading costs.Kung and Wong (2009) study moving average and trading breakout rules for Taiwanese stock market and suggest that these two rules have substantial predictive power for 1983-1990 period, less for the 1991-1997 period, and no power for the 1998-2005 period.They hence conclude that Taiwan stock market is more efficient in recent years.Likewise, Lai et al (2010) analyze technical analysis with psychological biases for Taiwan stock market and provide that disposition, information cascade, and anchoring effects each has certain influence on trading signals.Lento (2010), furthermore, employs some combined technical rules (CTR) and find that CTR is profitable on S&P 500 for the 1950-2008 period, even when individual trading rules alone are not profitable.Milionis and Papanagiotou (2011) explore alternative testing procedure for the predictive power of moving average rules for New York Stock Exchange (NYSE), the Athens Stock Exchange (ASE), and the Vienna Stock Exchange (VSE).They support the weak-form market efficiency for NYSE for the 1993-2005 period, reject for the ASE except for the 2001-2005 sub-period, and reject for VSE over the 1993-1997 period and accept for the other two sub-periods.Metghalchi and Garza-Gomez (2011) use some selected technical trading rules for the Abu Dhabi Stock Index and conclude that it cannot outperform the B&H strategy.Moreover, Mitra (2011) investigates the profitability of moving average trading rules for the Indian stock market and observes that profitable opportunities from technical analysis stay as a puzzle in the market.
The objective of this research is threefold.First we examine whether or not technical trading rules have predictive power for Taiwan stock market.Second, if technical trading rules show projecting power, we study which of the technical indicators or their combinations should be applied.Finally, if technical trading rules demonstrate predictive power, can we construct a trading strategy based on the rules to outperform the B&H strategy even considering for transaction costs and risks.Furthermore, we employ Hansen's (2005) Superior Predictive Ability (SPA hereafter) to solve for data snooping problems and also to rank the profitability of the trading rules.
The rest of the paper is organized as follows.Section 2 discusses the data and trading rules.Section 3 presents the empirical results.Section 4 compares various strategies with the B&H strategy.Section 5 addresses data snooping problems and solutions, and Section 6 concludes.

Data and Trading Rules
We use daily open, high, low, close, and volume of the Taiwanese stock index from November 15 th of 1990 to August 16 th of 2010.The starting date of the study was based on the availability of Taiwanese stock index.We use two MA rules in this study: the crossing of the index level (MA1) and moving averages of 20-day closing prices (MA20) and the crossing of MA1 and MA50.A buy (sell) signals are emitted when MA1 exceeds (falls below) the MA20 or MA50.Another three trading rules, which is RSI3, RSI9, and RSI14, are computed as follows: Where RS= the average of n days' up closes / the average of n days' down closes We can observe that RSI is a ratio of the upward price movement to the total price movement over a given period of days.The 14-period RSI is suggested by Wells Wilder (1978), and we also use 3-and 9-period RSI.RSI ranges from 0 to 100.A buy signal is emitted when the RSI is above 50 and we will be in the market as long as the RSI indicator is above 50.We will leave the stock market once RSI goes below 50.The rule of PSAR, furthermore, is explained as follows: when the index level is above (below) the PSAR value, we will be in (out of) the market.The model of Parabolic SAR is presented as follow: Where AF represents acceleration factor which increases by 0.02 every time when the extreme price is changed and capped at 0.20 as recommended by Wilder.EP i-1 , or extreme price, is the highest (lowest) price for the previous day.Another indicator used is the Histogram based on MACD which is the difference between two exponential moving averages (EMA).In this paper we focus on the most commonly used 12-and 26-day EMAs.A 9-day EMA of the MACD (the signal line) is then plotted on top of the MACD.The plot of this difference is presented as a Histogram, making centerline crossovers (the zero line) easily identifiable.

Histogram = MACD -Signal Line
A buy signal is triggered when the Histogram is positive and we will be in the market as long as the Histogram stays positive.We will be out of the market as soon as the Histogram becomes negative and stays negative.Another indicator used in this article is the Stochastic Oscillator which shows the location of a security's current close price relative to its price range over a given time period.The main line is represented by %K.Taking MA3 of %K, we produce %D.A N-day %K is computed as follow: By estimating MA3 of %D, a smoother version called Slow Stochastic is derived.In addition to the most commonly used 14-day period, we also use 9-day period.A buy signal (buy day) is emitted when %K is above %D and % D is increasing, otherwise we will be out of the market (sell day).Two volume indicators are also used in this research.The first one is MFI which is a volume-weighted momentum indicator that measures the rate at which the amount of capital is invested into and withdrawn from a security.It is related to RSI, but RSI only incorporates prices.MFI instead accounts for volume.The MFI compares the ratio of "positive" money flow and "negative" money flow.If the typical price measure (i.e.(Day high + day low + day close)/3) today is greater (less) than the one of yesterday, it is an uptick (downtick) or positive (negative) money flow.Then the MFI is derived from the ratio of positive/negative money flow or Money Ratio presented as follows: Using a 14-day MFI, a buy (sell) signal is triggered if MFI is above (below) 50 or stays above (below) 50.The second volume indicator adopted is OBV which is a momentum technical indicator that relates volume to price change.OBV is calculated by adding the day's volume to a running cumulative total when the security's price closes upward, and subtracts the volume when it closes downward.Suppose today the closing price is greater (less) than yesterday's closing price, then the new OBV = yesterday's OBV + (-) today's volume.Likewise, if today the closing price is identical to yesterday's closing price, then the new OBV = yesterday's OBV.In this study a buy (sell) signal is triggered if the OBV crosses the MA20 of OBV from below (above).
We assume that a trader following any of these trading rules could presumably observe the index prices just before the day's close and place a limit order conditional on the market's closing type to perform the trading rules.In the case of using MA strategy, for instance, if the closing price is greater than the long moving average, then the trader will be in the market the next day by buying the index at the closing price (i.e. next day will be a buy day), and vice versa.Next day's return will be the difference between the logarithm of the closing price next day and the logarithm of closing price the previous day.Although changes in stock price index do not include daily dividend yields, we do not expect this omission alter the results of our analysis.Mills and Coutts (1995) review the literatures regarding dividends and conclude that any bias in the results due to dividend exclusion will be minimal.Draper and Paudyal (1997) also support this conclusion.
For each trading rule we define the mean buy returns by B X , the mean sell returns by S X , and the mean B&H returns by H X as follows: is the total number of buy (sell) days, and N stands for the total number of observations (days).
B R and S R are the daily returns on buy and sell days while R is the daily stock returns.We then perform three tests to determine whether the mean buy or sell returns of each trading rule is different from the mean return of the B&H strategy and whether the mean return on buy days is the same as the mean return on sell days: Following Kwon and Kish (2002), the test statistic for the mean return on buy days over the mean B&H return (Test 1) is: VAR and H VAR are the variances of buy and B&H returns, respectively.The above formula is also used to test the mean sell return over the mean B&H return (Test 2) and the mean buy return over the mean sell return (Test 3) by replacing the appropriate variables.For two tailed test at 5% level, we compare all estimated t-statistics with the critical value of 1.96.

Empirical Results
Table 1 reports the results of the five best trading rules and the average of all 13 rules based on one indicator (Note 2).The table documents the mean daily buy ( B X ), the mean daily sell ( S X ), the mean daily buy minus sell, number of buy and sell days (N B and N S ) and standard deviations of daily returns (SD B and SD S ), and the number of total trades or in and out of the market for each trading rule and the average of the 13 single indicator rules.For the entire 20.83 years (5152 observations), the average daily return for the B&H strategy is 0.014 percent per day with standard deviation of 0.017.
The best single-indicator rules are based on RSI and MA rules.All of the mean buy returns are positive with highly significant t-statistics in the best five models, rejecting the null hypothesis that the mean buy returns equal zero.The same is true for the mean sell returns, except for MA20.As for buy minus sell days, all five rules have highly significant t-statistics, rejecting the null hypothesis of equality of the mean buy with the mean sell days.As for the average of all 13 models based on single indicator, the results are not as strong.On the average we cannot reject the null hypothesis that the mean returns equal zero for buy days and sell days alone.However the mean buy minus sell day for 13 models have significant t-statistics (i.e.3.10), rejecting the null hypothesis of equality of the mean buy with the mean sell days.Looking at the standard deviations, we observe that the market is more volatile in down market than in up market.For single indicator models, on the average we are 51% in the market and 49% out of the market.Out of 13 models, 7 mean buy days, 4 mean sell days, and 11 mean buy minus sell days have t-statistics greater than the critical value of 1.96.According to Table 1, we suggest that RSI and MA trading rules are more effective than MFI, OBV, DMS, Histogram, and Stochastic trading rules.Given that all buy, sell, buy minus sell for RSI and almost all buy, sell, buy minus sell for MA trading rules have highly significant t-statistics.We conclude that technical trading rules in Taiwanese stock market have predictive power and could discern recurring price patterns.
We next question on whether using more than one indicator could improve trading performance.Since the best single-indicator rules centers on RSIs and MAs, we combine these two indicators with other indicators.As a result we have established and tested a total of 25 trading models based on two indicators (Note 3) and 28 trading models based on three indicators (Note 4).Table 2 presents the results of the 7 best models and the average of all 25 models (last row) based on two technical indicators.Likewise, Table 3 reports the results of the 7 best models and the average of all 28 models based on three technical indicators.As we can see from Table 2, the best models are based on RSI, MA50, OBV, MFI, Stochastic, and PSAR.For all seven models the mean buy-day returns are all positive with highly significant t-statistics, rejecting the null hypothesis that the mean buy returns equal zero.Moreover, for all of the seven models, the mean buy minus sell returns are positive with highly significant t-statistics, rejecting the null hypothesis of equality of the mean buy with the mean sell days.Regarding the mean sell returns, four out of 7 have significant t-statistics, rejecting the equality of the mean sell returns with zero.As for the average of all 25 models based on two indicators, the t-statistics for buy day and buy minus sell day are significant, 2.52 and 3.58 respectively.More specifically, 21 out of 25 models have significant t-statistics for the mean buy day, six have significant t-statistics for the mean sell day, and 24 have significant t-statistics for the mean buy minus sell day.The standard deviation of buy and sell days are similar to the models with only one indicator.However the number of buy days is much lower than that based on single indicator; on the average two-indicator models are 38% in the market versus 51% for single indicator.It seems that there is a trade-off, as we increase the number of technical indicators, our results improve (21 significant buy days and 24 significant buy minus sell day) but the number of days in the market is reduced.We further investigate this consequence in the next section.
The results documented in Table 3 are interesting.All of buy days and buy minus sell days have significant t-statistics rejecting the null hypothesis of the equality of the buy day returns with zero and the equality of buy day returns with sell day returns.However, none of the sell days have significant t-statistics.For all of 28 models based on three indicators, 27 have significant statistics for buy days, 1 has significant sell day t-statistic and all of 28 have significant buy minus sell t-statistics.On the average the three-indicator models are in the market 33% of the time.As we increase the number of technical indicators in our trading model from 2 to 3, the number of buy days is reduced.However this does not help the sell-day returns since only one out of 28 sell-day returns has significant t-statistics.We suggest that increasing technical indicators from two to three does not seem to help trading performance.In summary, given the results of Tables 1, 2, and 3, we provide that technical trading rules have predictive power.If technical trading rules don't have any power to forecast price movements, we should observe that the buy-day returns do not differ appreciably from sell-day returns.However, all buy-day returns are different than sell-day returns in Table 3.Likewise, 24 out of 25 and 11 out of 13 trading rules have different buy-day returns than sell-day returns in Tables 2 and 1 respectively.In addition, for all of the 68 rules, the buy minus sell returns have highly significant t-statistics rejecting the null hypothesis of equality of the mean buy with the mean sell returns.The question now is whether a trader can use technical analysis to design a strategy and beat the B&H strategy after consideration for risk and transaction costs?

Trading Strategies
Given the predictive power of technical trading rules, we now consider whether it is possible to design technical trading strategies to beat the B&H strategy after considering for risk and transaction costs.A majority of the literature on technical analysis consider shorting the market when a rule emits a sell signal and we define this strategy as Market/Short (M/S).In addition to M/S strategy, we also consider three other strategies; the second strategy considered in this study is to be fully invested in the index when a rule emits buy signals and be in the money market when the rule emits sell signals.We name this strategy Market/Money (M/M).The third strategy involves borrowing an equal amount of the portfolio at the money market rate and double investment in the index when a rule emits buy signal and be in the money market when the rule emits sell signal.We call this strategy Leverage/Money (L/M).Finally our fourth strategy is Leverage/Short (L/S) in which we double the investment when buy signal is emitted and short the market when sell signal is triggered.The total return (TR) on buy days for a leverage strategy thus is computed as TR = (2×R)-M, where R and M are the index return and the money market rate respectively.We estimate the daily return for each strategy and then subtract the B&H return from it to get the Daily Difference Return (DDR).To test whether the mean DDR is different from zero, we construct the hypothesis below and estimate the related t-statistic: Where X(DDR) is the average DDR for each strategy over the B&H strategy, VAR(DDR) is the variance of DDRs, and N is the total number of days.In Table 4, 5, 6, and 7, we report the average DDR and its t-statistic, annual excess return (AER), number of trades per year, one way break-even cost (BEC), and the standard deviation of each strategy for our 19 models under consideration in which 5 based on one indicator, 7 based on two indicators, and 7 based on three indicators.The first row of Table 4, for instance, shows that for strategy 1 (i.e.long the market on buy days and park the money in the money market on sell days), the average DDR is 0.00054 per day which translates to 13.33 % of AER over the B&H per year.The t-statistic of 3.07 is highly significant rejecting the equality of the mean DDR from zero.For Strategy 1 and 3 (No shorting is involved) we estimate the average number of trades per year by dividing the total number of trades of each rule by 20.8333 years.For Strategy 2 and 4 when shorting is part of the strategies, the number of trades per year is twice of that of Strategy 1 and 3 for the same rule.For example, the average number of trades per year of Strategy 1 (Table 4) for RSI3 is 53.0 (1104/20.8333),but for the same rule it is 106 for Strategy 2 (Table 5).
The next column reports the one-way break-even costs (BECs) which are the one-way percentage costs that eliminate AER.BECs are estimated by summing up each day's excess return of each strategy over the 5152 days and dividing the result by the total number of trades.For the strategies involving shorting the market, we divide this sum by twice the number of trades.Finally the last column presents the risk (standard deviation) of each strategy and it should be compared with the standard deviation of the B&H strategy or 0.01665.Table 4 shows that the risk of Strategy 1 is lower than that of the B&H strategy, and this is expected since a trader is only part of the time in the market.Almost all of average DDRs are positive with significant t-statistics, implying that technical trading rules have predictive powers.The AERs are between 13.33% and a low of 7.89%.As for the BECs, they are between a high of 0.85% for MA50 and a low of 0.16%.Domowitz (2000) has estimated Taiwan's one-way equity transaction cost to be between 56 to 75 basis points.The only rule in Table 4 that would be profitable is the MA50 and the second best model is based on three indicators, RSI14 & MA50 & DMS.Both models could be profitable if the one-way equity transaction cost can be close to 0.5%.Since 2000 when Domowitz estimated various transaction costs, these costs have decreased substantially for many countries.We should also point out that the best two models for Strategy 1 have much lower risk than the B&H strategy.
Looking at the results of our 19 models for Strategy 2 (Table 5), we conclude that Strategy 2 is not as good as Strategy 1.Here the BECs are lower but risks are higher than those in Strategy 1.The best two models are the same as in Strategy 1 with BEC of 0.73% and 0.54%.On the average the risk of Strategy 2 is similar to the risk of B&H strategy, and this should be expected since we have the same return distribution.Since Strategy 2 involves shorting the market when a model emits sell signal, the average number of trades per year is double of that in Strategy 1 for the same rule.As a result, the number of trades is higher for this strategy than in Strategy 1 and since on the average the sell-day returns don't have high average return, the additional returns of shorting the market do not justify the additional transaction costs of higher frequency of trading.We hence conjecture that Strategy 2 is worth than Strategy 1.
Table 6 presents the results of Strategy 3 for the 19 models.For Strategy 3, all DDRs have significant t-statistics rejecting the null hypothesis of equality of the technical trading returns with the B&H returns.Again this confirms that technical trading has predictive power and can discern recurring price patterns.The AERs for Strategy 3 are high, mostly in the 20 percent additional return per year over the B&H strategy.The highest AER is 27.16% for RSI3 rule.Nevertheless, since RSI3 involves many in-and out-of-the-market movements, it is not the best rule for Strategy 3. The three best models for Strategy 3, instead, are MA50, RSI14 & MA50, and RSI14&MA50&DMS with BECs of 1.74%, 1.38%, and 1.31% respectively.However these three models have higher risk than that of the B&H.We thus have higher return but also higher risk.There are a few models that have similar risk as the B&H like RSI3&MA50 and RSI14&MA50&Histogram and RSI3&MA50&PSAR and RSI3&MA50&MFI with BECs of 0.72%, 1.28%, 0.73 %, 0.63% respectively.These four models have similar risk as the B&H but with AER in the 20%.The best model is the one based on three indicators (RSI14, MA50, Histogram) with a BEC of 1.28 % which is much higher than Domowitz's estimated one-way transaction cost.
Table 7 reports our findings for Strategy 4. The results for Strategy 4 are much worse than for Strategy 3, and the conclusion for Strategy 4 is similar as for Strategy 2. Shorting involves more trades and the average return of short days is not high enough to compensate for transaction costs of more trades.We therefore conclude that the number of trades and the risk, as evidenced by the last column of Table 7, are high but the additional returns for sell days are low so that overall this strategy is inferior to Strategy 3.

Robustness Test
Data snooping problem is likely to occur when a data set is reiteratively used for studies.To avoid such problem, we conduct robustness test for the trading rules we have analyzed.B&H strategy is the benchmark and we investigate whether or not the selected technical trading rules can outperform the benchmark.Sullivan, Timmermann, and White (1999) employ White's Reality Check (RC henceforth) established by White (2000) and solve for possible data snooping problem that may appear in technical trading.RC examines whether or not the benchmark model is superior to the selected technical trading rules.A deficiency of RC centers on the demand of constructing a complete collection of technical trading rules before the test.Hansen (2005) documents that the number of collected technical trading rules will affect the achievement of RC.Hence, to gather as many trading rules as possible become the major difficulty and problem of RC.As a result, Hansen (2005) develops Superior Predictive Ability (SPA, hereafter) that does not require a complete universe of trading rules to alleviate data snooping problem.A studentized test statistic and sample-dependent distribution are used in SPA and expected loss of the selected trading rules against the benchmark is evaluated.The null hypothesis is provided as: the B&H strategy is superior to all the technical trading rules.The mathematical equations of SPA test is given as follows.
Where S i,t indicates the variation of trading rule i's performance and the benchmark performance at time t.k represents the loss function and r stands for the random variable derived from decision rules d. d 0, t-h is the benchmark model and d i, t-h shows the trading rule.The expected variation of performance is , where v signifies vector.The studentized test statistics and the null hypothesis are given as follows.
Where m shows the number of samples,  indicates the estimator of the standard deviation of the S vectors, and S denotes for the average of the S vectors.We use bootstrap methodology to evaluate the loss function, and the number of re-sampling and the bootstrap parameter are amended at proper levels.Mean squared error (MSE) and mean average error (MAE) are adopted as the loss function.
The result of the robustness tests is presented in Table 8.The tests help to determine the best, top 25%, median, 75%, and the worst technical rule/strategy with the combination of MSE/MAE, 10000 re-samplings, and dependence of 0.25, 0.5, and 0.75.In general, we observe that the single-indicator rule, which is MFI14>50, shows the best profitability across all combinations.Moreover, 3-indicator strategies appear to perform worse than 2-indicator strategies.In other words, the empirical evidence provides an inverse connection between the combination of the number of technical indicators and profitability.Also observed is that these statistics are quite significant across the models tested by different bootstrap parameters, rejecting the hypothesis that the benchmark trading strategy is not inferior to our selected trading strategies in view of data snooping problem.

Conclusions
We use daily open, high, low, close, and volume of the Taiwanese stock index from November 15 th of 1990 to August 16 th of 2010 to investigate the profitability and riskiness of several technical trading rules based on 9 popular technical indicators.Overall our findings provide strong support for the predictive power of technical trading rules.If technical analysis does not have any predictive power, then we should observe that the mean buy-day returns do not differ appreciably from the mean sell-day returns.The empirical evidence shows that 58 out of 66 models tested have significant t-statistics rejecting the null hypothesis of equality of the mean buy-day returns with the mean sell-day returns.
Given that technical trading works, which rule or combination of rules should be used?Can a trader design a strategy based on the technical rules to beat the B&H strategy after considering for risk and transaction cost?The answer is not straightforward, in general, and those rules that involve many in-and out-of-the-market movements, despite having high AER, should be avoided since the transaction costs eat up the additional returns.Furthermore the strategies that involve shorting are inferior to the strategies that park the money in the money market when a rule emits sell signal.For single-indicator models, the famous MA50 works the best.MA50 with Strategy one (Market/Money) has a BEC of 0.85 which is higher than the one-way BEC for Taiwan and has a standard deviation of 0.01081which is much lower than the risk of B&H.
In addition, if a trader's risk tolerance is high, one can use MA50 with Strategy 3 (Leverage/Money).Such combination has a very high BEC of 1.74% and also has a risk of 0.02161 which is bit higher than the B&H risk.We suggest that technical trading rules have predictive powers but it is not straightforward to design a strategy to beat the buy-and-hold strategy after considering for risk and transaction costs.We have considered 66 models based on 9 popular technical indicators, and only a few could have higher returns and similar risk than the B&H strategy.Overall our best model for Strategy 1 is the famous MA50 and our best model for Strategy 3 is based on three indicators, RSI14&MA50&Histogram. Finally, we provide robustness test and it shows that the association between the combination of the number of technical indicators and profitability is inverse.
For the money market rate, we use Taiwan 10-day middle rate.All data are collected from Datastream and expressed in Taiwan dollar.The technical indicators employed in this article are Moving Averages (MA), Relative Strength Index (RSI), Parabolic Stop and Reverse (PSAR), Directional Moving System (DMS), Histogram, Stochastic, Money Flow Index (MFI) (Note 1), and finally Joseph Granville's (1976) On Balance Volume (OBV).Overall we test 66 trading rules based on the above indicators: 13 trading rules are based on one indicator only, 25 are from two indicators, and 28 are based on three indicators.The concepts of the technical indicators are described as follows.

Table 1 .
One-indicator Trading Rules The figures inside the brackets are the t-statistics.The numbers marked with * denote statistical significance at the 5% level for a two-tailed test.

Table 3 .
Three-indicator Models The numbers marked with * denote statistical significance at the 5% level for a two-tailed test.

Table 4 .
Strategy 1 (Market/Money) DDR) is the average of daily returns of Strategy 1 over the B&H returns.t-statistics test the equality of average daily difference returns from zero.AER is the annual excess return of Strategy 1 over the B&H strategy.BEC is the one way break-even cost, and SD is the standard deviation.

Table 5 .
Strategy 2 (Market/Short) DDR) is the average of daily returns of Strategy 2 over the B&H returns.t-statistics test the equality of average daily difference returns from zero.AER is the annual excess return of Strategy 2 over the B&H strategy.BEC is the one way break-even cost, and SD is the standard deviation.

Table 6 .
Strategy 3 (Leverage/Money) DDR) is the average of daily returns of Strategy 3 over the B&H returns.t-statistics test the equality of average daily difference returns from zero.AER is the annual excess return of Strategy 3 over the B&H strategy.BEC is the one way break-even cost, and SD is the standard deviation.