Stock Price Prediction of Apple Based on SVM and KNN

Authors

  • Xingyu Liu
  • Yizan Ni
  • Bo Yang

DOI:

https://doi.org/10.54691/bcpbm.v34i.3107

Keywords:

stock price prediction; machine learning; logistic regression; KNN; SVM.

Abstract

Stock price prediction using machine learning has always been an enigmatic program for many researchers. Different models suit different circumstances, even though they are all after the same result. In addition, stock prices appear to be no upper or lower bound on how values can rise or fall. Therefore, studying stock price prediction can be very important to shareholders or investors. However, one of the research significances of this essay is about understanding more about machine learning in python while knowing how to use this knowledge of machine learning flexibly for a specific circumstance. Also, successfully using all the data from seven days ago to predict the rise and fall of the eighth day to help eliminate the hesitation of purchasing is another significant meaning for this study. For this research, logistic regression, KNN (K- Nearest Neighbors), and SVM (support vector machine) are selected to compare their advantages and disadvantages in this project. Three models are individually evaluated in this essay, by observing the accuracy value, which is the percentage of test examples that were properly categorized relative to all test instances, and the classification of predicting the rise and fall of stocks. Combining all the considerations, the result shows that the accuracy of the SVM model is higher than the other two models. Additionally, python, which is a superior code language for machine learning, has been chosen for this project.

Downloads

Download data is not yet available.

References

Kumar, N. (2022, August, 23th). Understanding Logistic Regression.

Retrieved from https://www.geeksforgeeks.org/understanding-logistic-regression/

Hashmi, F. (2022). How to create an SVM model for regression in Python. Retrieved from https://thinkingneuron.com/how-to-create-an-svm-model-for-regression-in-python/

Vladimir, V. (2022). Support vector clustering. Journal of Machine Learning Research, 2.125-137.

Altman, N. S. (2022). An introduction to kernel and nearest-neighbor nonparametric regression. Retrieved from https://www. tandfonline.com/ doi/abs/10.1080/00031305.1992.10475879

Kijewska A . Determinants of the return on equity ratio (ROE) on the example of companies from metallurgy and mining sector in Poland[J]. Metalurgija -Sisak then Zagreb-, 2016, 55(2):285-288.

Prasanna .(2022). Advantages and Disadvantages of Machine Learning | Pros and Cons of Machine Learning, Drawbacks and Benefits. Retrieved from https://www. aplustopper.com/advantages-and-disadvantages-of-machine-learning/#Advantages_of_Machine_Learning/

Levy, Steven. "Apple Inc.". Encyclopedia Britannica, 31 Aug. 2022, Retrieved from https://www. britannica.com/topic/Apple-Inc. Accessed 24 September 2022.

Sperandei, S. (2014). Understanding logistic regression analysis. Retrieved from https://pubmed.ncbi.nlm.nih.gov/24627710/

Bansal, S. (2021,July,7th). Introduction to SVM – Support Vector Machine Algorithm of Machine Learning. Retrieved from https://www. analytixlabs.co.in/blog/introduction-support-vector-machine-algorithm/

Chatterjee, M. (2020,Feb,3rd) A Quick Introduction to KNN Algorithm Retrieved from https://www. mygreatlearning.com/blog/knn-algorithm-introduction/

Downloads

Published

2022-12-14

How to Cite

Liu, X., Ni, Y., & Yang, B. (2022). Stock Price Prediction of Apple Based on SVM and KNN. BCP Business & Management, 34, 873-878. https://doi.org/10.54691/bcpbm.v34i.3107