Research on a Temperature Prediction Model for Meteorological Data Integrating XGBoost and MLP
摘要
This study develops an efficient temperature prediction model by integrating multiple machine learning techniques to enhance the accuracy of meteorological data analysis. Utilizing ten years of meteorological data encompassing features such as relative humidity, cloud cover, visibility, precipitation, wind speed, and sunshine duration, we performed comprehensive data preprocessing and feature selection. Initially, missing values were addressed, and wind direction was encoded. Important features were then identified using the mutual information method. Subsequently, data normalization was carried out through standardization, and temporal as well as lag features were extracted to bolster the model’s predictive capabilities. For model construction, we selected XGBoost (Extreme Gradient Boosting) and MLP (Multilayer Perceptron) as base models and employed linear regression as the final predictor, thereby establishing a stacked regression framework. The dataset was divided into training and testing sets with an 8:2 ratio. The model achieved a Root Mean Squared Error (RMSE) of 1.34 and a Coefficient of Determination (R2) of 0.98 on the training set, and an RMSE of 1.74 and R2 of 0.97 on the testing set. Additionally, 5-fold cross-validation yielded an average RMSE of 1.92, demonstrating the model’s stability and generalization performance.