摘要
基于天气数据进行空气质量预测,首先收集成都市A区2018年4月1日到2018年6月3日64天24个天气属性,然后对天气属性进行筛选、数据处理;接着,建立KNN分类模型,利用k折交叉验证和多数表决原则对64个样本进行分类;最后在传统KNN分类模型的基础上,使用反距离加权建模,结果表明模型有较好的泛化能力和预测效果。
This paper forecasts air quality based on weather data.24 weather attributes from April 1,2018 to June 3,2018 are collected from April 1,2018 to June 3,2018.Then,the KNN classification model is established,and 64 samples are classified by k fold cross verification and majority voting principle.Finally,on the basis of the traditional KNN classification model,the model is established by inverse distance weighting,and the results show that the model has good generalization ability and prediction effect.
作者
郑茂波
孟佳俊
鲁越
ZHENG Maobo;MENG Jiajun;LU Yue
出处
《科技创新与应用》
2020年第34期37-38,41,共3页
Technology Innovation and Application
基金
四川省教育厅项目(编号:17ZB0026)
四川省大学生创新训练项目(编号:201611116048)。
关键词
天气数据
空气质量
k折交叉验证
反距离加权
KNN算法
weather data
air quality
k fold cross verification
inverse distance weighting
KNN algorithm