COMPARISON K-NN REGRESSION AND SVR MSE IN 5 MOST ACTIVE STOCK BASED ON HISTORICAL DATA

Michael The, Rosita Herawati

Abstract


This project aims to address the challenge of accurate stock price prediction by comparing the error prediction of two popular machine learning algorithms, K-Nearest Neighbors Regressor (KNN-R) and Support Vector Regressor (SVR) based on historical stock data. Based on previous research about stock prediction, the study evaluates the error in predicting future stock prices based on features such as historical price and volume. The SVR is evaluated for its ability to fit a regression model that minimizes prediction errors. In terms of accuracy, KNN Regression is hypothesized to outperform SVR. The models are trained and rested across multiple stock datasets, and results indicate that SVR consistently achieves superior predictive performance compared to KNN Regression. These findings highlight the importance of selecting the right algorithm for stock price prediction

Keywords


stock prediction, K-Nearest Neighbors Regression, Support Vector Regression, accuracy, historical data

Full Text:

PDF

References


R. K. Nayak, D. Mishra, and A. K. Rath, “A Naïve SVM-KNN based stock market trend reversal analysis for Indian benchmark indices,” Appl. Soft Comput., vol. 35, pp. 670–680, Oct. 2015, doi: 10.1016/j.asoc.2015.06.040.

V. Sarala, “Stock Market Trend Prediction Using K-Nearest Neighbor (KNN) Algorithm,” J. Eng. Sci., vol. 13, no. 08, 2022.

K. Nakagawa, M. Imamura, and K. Yoshida, “Stock Price Prediction with Fluctuation Patterns Using Indexing Dynamic Time Warping and $$k^*$$-Nearest Neighbors,” in New Frontiers in Artificial Intelligence, S. Arai, K. Kojima, K. Mineshima, D. Bekki, K. Satoh, and Y. Ohta, Eds., Cham: Springer International Publishing, 2018, pp. 97–111. doi: 10.1007/978-3-319-93794-6_7.

O. D. Madeeh and H. S. Abdullah, “An Efficient Prediction Model based on Machine Learning Techniques for Prediction of the Stock Market,” J. Phys. Conf. Ser., vol. 1804, no. 1, p. 012008, Feb. 2021, doi: 10.1088/1742-6596/1804/1/012008.

M. Ghosh and R. Gor, “STOCK PRICE PREDICTION USING SUPPORT VECTOR REGRESSION AND K-NEAREST NEIGHBORS: A COMPARISON,” International Journal of Engineering Science Technologies, vol. 6, no. 4, Art. no. 4, Jul. 2022, doi: 10.29121/ijoest.v6.i4.2022.354.

M. Rehman, M. Fuzail, M. K. Abid, and N. Aslam, “Financial Prices Prediction of Stock Market using Supervised Machine Learning Models,” VFAST Transactions on Software Engineering, vol. 11, no. 2, Art. no. 2, May 2023, doi: 10.21015/vtse.v11i2.1439.

Y. Huang, “Research on the Google Stock Price Prediction Based on SVR, Random Forest, and KNN Models,” Highlights in Business, Economics and Management, vol. 24, pp. 1054–1058, Jan. 2024, doi: 10.54097/n8hxqx19.

S. Islam, Md. S. Sikder, Md. F. Hossain, and P. Chakraborty, “Predicting the daily closing price of selected shares on the Dhaka Stock Exchange using machine learning techniques,” SN Bus Econ, vol. 1, no. 4, p. 58, Mar. 2021, doi: 10.1007/s43546-021-00065-6.

J. Kaliappan, K. Srinivasan, S. Mian Qaisar, K. Sundararajan, C.-Y. Chang, and S. C, “Performance Evaluation of Regression Models for the Prediction of the COVID-19 Reproduction Rate,” Front. Public Health, vol. 9, Sep. 2021, doi: 10.3389/fpubh.2021.729795.

H. Zhao and Y. Chen, “A Comparative Study for Temperature Prediction by Machine Learning and Deep Learning,” in 2023 International Conference on Intelligent Computing and Control (IC&C), Feb. 2023, pp. 77–84. doi: 10.1109/IC-C57619.2023.00020.




DOI: https://doi.org/10.24167/proxies.v8i2.13002

Copyright (c) 2025 Proxies : Jurnal Informatika



View My Stats