Stock Market Prediction using SVM, LSTM and Linear Regression
Nethmal Warusamana 1 , Amila Indika 1* , Erantha Welikala 1 and Sampath Deegalla 1
1
Department of Computer Engineering, Faculty of Engineering, University of Peradeniya, Sri Lanka
*E-mail: [email protected]
Abstract: The Stock market is a decisive section in the economy of a country. Using computer-based learning
methodologies have become a prominent characteristic in modern stock trade.
Stock prices are highly volatile and are affected by economic, social & political factors. Businesses & investors
are on a constant lookout for tools & technologies to get insights regarding stock variations to reap financial
benefits. But existing stock prediction models have low accuracies in terms of prediction (confirmed through the
literature review).
Through this research, different machine learning, statistical and neural network model performances are assessed
regarding stock prediction. The problem (low accuracies) is approached as a classification and a regression.
The models used in this research are Long Short Term Memory (LSTM) neural networks, Linear Regression
(as a regressor), and Support Vector Machines - SVM (as a classifier). Detailed research performed through
the aforementioned models is presented regarding multiple companies. Specifically, 10 years of historical stock
prices of the most active 20 companies of the NASDAQ stock exchange have been used.
Through this study, it is evident that SVM is considerably under-performing while linear regression has proven
to produce promising results. Results of LSTM are satisfactory, but not up to par with linear regression. One of
the key findings is that SVMs failed to capture the pattern in time-series financial data with respect to the classification.
As future endeavors, individual results of these models can be combined to develop an ensemble model
and the prediction accuracy can be improved further.
Keywords -LSTM, SVM,Ensemble, Stock Market Prediction, Regression, Classification, Financial Forecasting
21