摘要
为了对汇率进行预测,提出了基本最邻近(KNN)算法,并介绍了它的基本原理,构建了最近邻算法.为了提高预测的准确性,对传统的KNN算法进行了改进,提出了加权KNN算法.同时,为了对所提出的算法进行验证,进行了实证研究,并对传统KNN算法和加权KNN算法的预测结果进行了误差对比分析,从而得出结论,改进的KNN算法能够更加准确地预测汇率.最后,分析了加权KNN算法的优缺点,并提出了展望,KNN算法可以应用到股票价格趋势预测等相关领域.
In order to predict the exchange rate, first, the basic nearest neighbor (KNN) algorithm and its basic principles are proposed in this paper, so the nearest neighbor algorithm is established. Second, for improving the accuracy of the prediction, the traditional KNN algorithm is improved, and based on the above a weighted KNN algorithm is proposed. Third, the empirical results of traditional KNN algorithm and weighted KNN algorithm are compared and analyzed to verify the proposed algorithm. It is concluded that the improved KNN algorithm can predict the exchange rate more accurately. Finally, the advantages and disadvantages of weighted KNN algorithm are analyzed that the KNN algorithm can be applied to the forecast of stock price.
出处
《兰州文理学院学报(自然科学版)》
2017年第3期27-31,共5页
Journal of Lanzhou University of Arts and Science(Natural Sciences)
基金
数学建模竞赛引领大学生科研创新的研究(acjyzd201429)
国家级大学生创新创业训练计划(201610378418)
关键词
汇率预测
KNN算法
加权KNN算法
改进
exchange rate forecast
KNN algorithm
weighted KNN algorithm
improvement