ISSN: 2056-3736 (Online Version) | 2056-3728 (Print Version)

The Trend is Your Friend: A Note on An Ensemble Learning Approach to Finding It

Tzu-Pu Chang, Yu-Cheng Chang and Po-Ching Chou

Correspondence: Tzu-Pu Chang,

Department of Finance, National Yunlin University of Science and Technology, Taiwan

pdf (553.15 Kb) | doi:


The essential goal of trend-following investing is to precisely identify where the uptrend and downtrend are located. This paper thus provides a two-layer stacking technique, which is a novel ensemble learning approach, to predict such trends for the Taiwan Top 50 ETF. The proposed stacking technique stacks the predictors of support vector machine (SVM), multi-layer perception (MLP), adaptive boosting (Adaboost), and extreme gradient boosting (Xgboost), presenting empirical results whereby following the trends obtained from the stacking technique can generate positive returns and beat both conventional moving-average crossover and buy-and-hold strategies.


  Trend-following investing; Stacking technique; Ensemble learning; Machine learning; Taiwan Top 50 ETF


Ballings, M., D. Van den Poel, N. Hespeels, and R. Gryp (2015), ‘Evaluating Multiple Classifiers for Stock Price Direction Prediction’, Expert Systems with Applications, 42, 7046-7056.Chen, S.S. (2009), ‘Predicting the Bear Stock Market: Macroeconomic Variables as Leading Indicators’, Journal of Banking & Finance, 33, 211-223.Clare, A., J. Seaton, P.N. Smith, and S. Thomas (2016), ‘The Trend is Our Friend: Risk Parity, Momentum and Trend Following in Global Asset Allocation’, Journal of Behavioral and Experimental Finance, 9, 63-80.Colombo, E., G. Forte, and R. Rossignoli (2019), ‘Carry Trade Returns with Support Vector Machines’, International Review of Finance, 19, 483-504.Duong, T.V.P., S.H. Lin, H.H. Lai, and T.P. Chang (2021), ‘Macroeconomic Variables for Predicting Bear Stock Markets of Taiwan and China’, International Journal of Emerging Markets, Forthcoming.Faber, M.T. (2007), ‘A Quantitative Approach to Tactical Asset Allocation’, The Journal of Wealth Management, 9, 69-79.Henrique, B.M., V.A. Sobreiro, and H. Kimura (2019), ‘Literature Review: Machine Learning Techniques Applied to Financial Market Prediction’, Expert Systems with Applications, 124, 226-251.Huang, W., Y. Nakamori, and S.Y. Wang (2005), ‘Forecasting Stock Market Movement Direction with Support Vector Machine’, Computers & Operations Research, 32, 2513-2522.Hurst, B., Y.H. Ooi, and L.H. Pedersen (2017), ‘A Century of Evidence on Trend-Following Investing’, The Journal of Portfolio Management, 44, 15-29.Levine, A., L.H. Pedersen (2016), ‘Which Trend is Your Friend’, Financial Analysts Journal, 72, 51-66.Menkhoff, L. (2010), ‘The Use of Technical Analysis by Fund Managers: International Evidence’, Journal of Banking & Finance, 34, 2573-2586.Neely, C. J., R.D. Rapach, J. Tu, and G. Zhou (2014), ‘Forecasting the Equity Risk Premium: The Role of Technical Indicators’, Management Science, 60, 1772-1791.Nyberg, H. (2013), ‘Predicting Bear and Bull Stock Markets with Dynamic Binary Time Series Models’, Journal of Banking & Finance, 37, 3351-3363.Nti, I.K., A.F. Adekoya, and B.A. Weyori (2020), ‘A Comprehensive Evaluation of Ensemble Learning for Stock-Market Prediction’, Journal of Big Data, 7, 1-40.Papadamou, S., and S. Tsopoglou (2001), ‘Investigating the Profitability of Technical Analysis Systems on Foreign Exchange Markets’, Managerial Finance, 27, 63-78.Raj, M., and D. Thurston (1996), ‘Effectiveness of Simple Technical Trading Rules in the Hong Kong Futures Markets’. Applied Economics Letters, 3, 33-36.Smith, D. M., N. Wang, Y. Wang, and E.J. Zychowicz (2016), ‘Sentiment and the Effectiveness of Technical Analysis: Evidence from the Hedge Fund Industry’, Journal of Financial and Quantitative Analysis, 51, 1991-2013.Tsai, C.F., Y.C. Lin, D.C. Yen, and Y.M. Chen (2011), ‘Predicting Stock Returns by Classifier Ensembles’, Applied Soft Computing, 11, 2452-2459.