Skip to main content
Advertisement
Browse Subject Areas
?

Click through the PLOS taxonomy to find articles in your field.

For more information about PLOS Subject Areas, click here.

  • Loading metrics

Monthly pork price forecasting method based on Census X12-GM(1,1) combination model

Abstract

Background

In recent years, the price of pork in China continues to fluctuate at a high level. The forecast of pork price becomes more important. Single prediction models are often used for this work, but they are not accurate enough. This paper proposes a new method based on Census X12-GM(1,1) combination model.

Methods

Monthly pork price data from January 2014 to December 2020 were obtained from the State Statistics Bureau(Mainland China). Census X12 model was adopted to get the long-term trend factor, business cycle change factor and seasonal factor of pork price data before September 2020. GM (1,1) model was used to fit and predict the long-term trend factor and business cycle change factor. The fitting and forecasting values of GM(1,1) were multiplied by the seasonal factor and empirical seasonal factor individually to obtain the fitting and forecasting values of the original monthly pork price series.

Results

The expression of GM(1,1) model for fitting and forecasting long-term trend factor and and business cycle change factor was X(1)(k) = −1704.80e−0.022(k−1) + 1742.36. Empirical seasonal factor of predicted values was 1.002 Using Census X12-GM(1,1) method, the final forecast values of pork price from July 2020 to December 2020 were 34.75, 33.98, 33.23, 32.50, 31.78 and 31.08 respectively. Compared with ARIMA, GM(1,1) and Holt-Winters models, Root mean square error (RMSE), mean absolute percentage error (MAPE) and mean absolute error (MAE) of Census X12-GM(1,1) method was the lowest on forecasting part.

Conclusions

Compared with other single model, Census X12-GM(1,1) method has better prediction accuracy for monthly pork price series. The monthly pork price predicted by Census X12-GM(1,1) method can be used as an important reference for stakeholders.

Introduction

In many country, pork is one of the daily necessities for most ordinary families. According to statistics, China needs about 54 million tons of pork every year, but the data released by National Bureau of statistics(Mainland China), pork output in 2019 is only 42.55 million tons, which shows that there is still a big gap between this quantity and the actual demand. Although pig breeding enterprises and individuals have also applied some innovative technologies to expand the production of pigs, the imbalance between supply and demand of pork is still an important factor affecting the price of pork in China [1]. The rising price of pork in 2019 is also an important factor leading to the continuous rise of China CPI [2]. The stability and controllability of pork price is not only related to the living standard of ordinary people, but also reflects the level of national governance in a sense.

Through the analysis of pork price trend, government departments can formulate strategies according to local conditions [3], such as encouraging breeding, putting government reserve pork into the market, or taking restrictive measures. Understanding the change of pork price in advance can also make farmers, middlemen and final consumers prepare for the follow-up plan [4]. For example, farmers can decide whether to expand the scale, middlemen can decide whether to increase or reduce the quantity of pork stocks, and final consumers may also consider whether to replace pork with other food. It takes about six months for a pig to become a marketable pork commodity from birth, that is to say, the price changes in the next six months are most meaningful for stakeholders [5].

Nowadays, there are many mathematical models that can be used to fit and predict time series data [6]. The monthly pork price data are a kind of typical time series. The models commonly used to fit and forecast time series include ARIMA model, grey system model, Holt winters exponential smoothing model and so on. With the development of artificial intelligence technology, various kinds of neural network technology are also used to forecast time series [79]. In addition, in order to analyze the factors that affect the change of time series, Census X12 model is used to decompose the seasonal and long-term change trend of time series [1012]. In order to improve the accuracy of time series prediction, multiple model combination method is also widely used [1316].

GM (1,1) model is one of the most important models for time series prediction [17]. It is one of the core contents of the grey system theory established by Professor Deng Julong in 1982 [18]. It describes the dynamic changes of time series by establishing a first-order linear ordinary differential equation. Its characteristic is that it can use a small amount of data to model and predict the series data. GM (1,1) model can be used to predict a wide range of time series, such as traffic data prediction [1922], financial data prediction [23, 24], agricultural data prediction, weather data, geological disaster data, disease prevention and control data, etc [2528]. At the same time, in order to further improve the prediction accuracy, GM (1,1) model is also combined with other models [2932].

In this paper, a new model combination method based on Census X12 model and GM (1,1) model was used to fit and forecast monthly pork price series. By comparing the prediction results of this method with other models, it was proved that X12-GM(1,1) model combination method has higher prediction accuracy. In the process of forecasting monthly pork price time series using Census X12-GM(1,1) method, a calculation parameter called empirical seasonal factor was constructed. When Census X12-GM(1,1) method is applied to other types of time series, the calculation formula of the empirical seasonal factor may be different.

Materials and methods

Materials source

The original monthly pork price data from January 2014 to December 2020 were collected from the National Bureau of statistics(Mainland China). We divided the sample data into two parts, the data from January 2014 to June 2020 were used for model fitting, and the data from July 2020 to December 2020 were used to evaluate the accuracy of model prediction.

Census X12 model

The traditional time series analysis method divides the fluctuation of time series into four factors: long-term trend change factor (T), seasonal change factor (S), business cycle change factor (C) and irregular change factor (I). Census X12 model is a decomposition method of seasonal factor of time series. Based on the different degree of independence between the factors, the model can be divided into additive decomposition model and multiplicative decomposition model.

The basic principle of Census X12 is to decompose the long-term trend change factor and business cycle change factor by the centralized moving weighted average method. The seasonal change factor is obtained by dividing the monthly data average of the time series by the total average, and the irregular change factor is obtained by dividing the original series by the long-term trend change factor, business cycle change factor and seasonal change factor. The algorithm of Census X12 multiplication model is shown as follows:

Step one: Initial estimate of seasonal adjustment

After centralization of 12 items moving average, By 3 × 3 moving average process, the initial estimation of seasonal factor St has After eliminating the residual trend of season factor, So, after seasonal adjustment, the initial estimation has

Step two: Calculation of tentative trend cycle factor and final season factor

Using “Henderson” moving average formula, tentative trend cycle factor can be calculated. That is Among them, is “Henderson” moving average coefficient. Then By 3 × 5 moving average process, tentative season factor can be calculated. That is So, final season factor can be drawn. That is At this point, second estimate results of seasonal adjustment shows as follows

Step three: Calculation of final trend cycle factor and season factor

Using “Henderson” moving average fourmula, final trend cycle factor can be calculated. That is So final season factor has So far, the final decomposition multiplication model of series Yt can be expressed as

GM(1,1) model

The grey prediction theory was put forward by Chinese scholar Deng Julong in 1982. This method mainly aims at small samples with little data and missing information. In grey system theory, GM (1,1) model is the most basic time series prediction model. It can model and predict according to a small amount of information. The modeling process of GM (1,1) model is shown as follows:

Step one: The original sequence of GM (1,1) model was established.

That is

Step two: Establishing one time accumulation generating sequence of the original sequence of GM (1,1) mode.

That is Among them,, k = 1,2,…,n, the purpose is to eliminate the contingency and instability of the original data.

Step three: The mean generation sequence of X(1) is established as follows Among them, z(1)(k) = 0.5 × (z(1)(k) + z(1)(k − 1), k = 1,2,…,n.

Step four: Constructing data matrix B and data vector Y, solving the values of development coefficient a and grey action quantity b.

x(0)(k) + az(1)(k) = b is the mean form of GM(1,1) model, and is the whitening differential equation of GM(1,1) model.

Therefore, the time response equation of the model is If k = 1, then x(1)(1) = x(0)(1). So far, the original time series can be fitted and predicted by . can be expressed as

Finally, Whether the GM (1,1) model can be applied to practical problems needs to be judged, and generally the average relative error, correlation degree, mean square error ratio and other indicators need to be verified.

Census X12-GM(1,1) method

The algorithm of census X12-GM (1,1) method is divided into the following steps:

Step one: Acquisition of the original time series (Yt)

Step two: Factor decomposition of the original time series (Yt)

Census X12 model is used to decompose the component factors of the original time series (Yt). The result is that the original time series (Yt) is decomposed into long-term trend change factor, business cycle change factor (TC), seasonal change factor (S) and irregular change factor (I).

Step three: Fitting and forecasting of long-term change factor, business cycle cycle change factor (TC)

In this step, the GM(1,1) model is used. The fitting value and prediction value () of the long-term trend change factor and the business cycle change factor (TC) are obtained.

Step four: Multiplication operation of The fitting value and prediction value () and seasonal change factor (S)

It should be noted that the fitting value is multiplied by the seasonal factor of the original time series at the corresponding time point, and the predicted value is multiplied by a empirical value (Sem) and the empirical value is calculated as follows: yn and yn−1 represent the last two values of the original sequence to be predicted.

Finally, the fitting value and prediction value () of the original time series data (Yt) based on X12-GM(1,1) method are obtained.

The algorithm flow chart of Census X12-GM (1,1) method is shown in Fig 1.

Comparison of prediction accuracy

In order to evaluate the prediction accuracy of different methods, this paper uses root mean square error (RMSE), mean absolute percentage error (MAPE), mean absolute error (MAE) as evaluation indexes [33, 34]. These indexes are espressed as:

Data processing and analysis

Excel 2013 software was used to store the original monthly pork price time series from the National Bureau of statistics(Mainland China). Eview 9 software was used to build census X12 model and GSTA 7 software was used to build GM (1,1) model. The curve of fitting value and predicted value of Census X12-GM (1,1) method was also drawn by Eview 9 software.

Results

Overview of original monthly pork price time series

A total of 84 numbers were collected to develop Census X12-GM(1,1) method. Fig 2 showed the change trend of the monthly pork price time series from the National Bureau of statistics(Mainland China). It could be seen from the figure that this time series had obvious business seasonal fluctuation and long-term trend characteristics. This time series had a relative peak from March 2015 to June 2017, and it started to rise from February 2019, and this trend was continued to November 2019. After November 2019, this time series began to fluctuate sharply at a high level.

thumbnail
Fig 2. Monthly price of pork from January 2014 to December 2020.

https://doi.org/10.1371/journal.pone.0251436.g002

Acquisition of component factors using Census X12 model

Census X12 model can be divided into multiplication model and addition model. This paper used Census X12 multiplication model to decompose the original monthly pork price time series from January 2014 to June 2020. The decomposing process did not consider the impact of traditional holidays on the data fluctuation. The decomposing results were as follows: Fig 3 showed the curve of long-term trend change factor and business cycle change factor (TC), Fig 4 showed the curve of seasonal factor, and Fig 5 showed the curve of irregular factor.

thumbnail
Fig 3. The curve of TC factor from January 2014 to June 2020.

https://doi.org/10.1371/journal.pone.0251436.g003

thumbnail
Fig 4. The curve of seasonal factor from January 2014 to June 2020.

https://doi.org/10.1371/journal.pone.0251436.g004

thumbnail
Fig 5. The curve of irregular factor from January 2014 to June 2020.

https://doi.org/10.1371/journal.pone.0251436.g005

Fitting and forecasting with GM (1,1) model

Next, the GM (1,1) model was built using the time series composed of long-term trend change factor and business cycle change factor (TC). Finally, we got the GM (1,1) model: X(1)(k) = −1704.80e−0.022(k−1) + 1742.36. It should be noted that the model only used the long-term trend change factor and business cycle change factor (TC) of March 2020, April 2020, May 2020 and June 2020. There were two reasons for using these four data in modeling. On the one hand, the GM (1,1) model based on static data has a very good fitting effect, but the model fitting is not our key task. On the other hand, GM (1,1) model is more suitable for small sample and scarce data. Three to five sample points are enough [35]. The predicted values of long-term trend change factor and business cycle change factor (TC) obtained by GM (1,1) model were shown in Table 1.

thumbnail
Table 1. The predicted values of TC from July 2020 to December 2020.

https://doi.org/10.1371/journal.pone.0251436.t001

Calculation of final fitting value and predicted value with Census X12-GM(1,1) method

Using Census X12 model, the seasonal factor of the original monthly pork price time series had be obtained. Using GM (1,1) model, the fitting value and predicted value of long-term trend change factor and business cycle change factor (TC) had be obtained. Census X12-GM (1,1) method was to multiply the above two kinds of data according to the corresponding time points. Here, It should be noted that the empirical seasonal factor(1.002) was multiplied by the predicted value. The empirical seasonal factor was obtained by special calculation. The final predicted value obtained by Census X12-GM(1,1) method was shown in Table 2.

thumbnail
Table 2. The final predicted values of the original series from July 2020 to December 2020.

https://doi.org/10.1371/journal.pone.0251436.t002

Comparison of different methods

In order to compare the accuracy of different methods for forecasting the original monthly pork price time series, the original values of October 2020, November 2020 and December 2020 in the original monthly pork price time series and the predicted values of other methods include Census X12-GM(1,1) method, ARIMA model, GM (1,1) model and Holt-Winters model were shown in Table 3. Meanwhile, the prediction error indexes of the above four methods were also calculated and shown in Table 4. The above indexes proved that Census X12-GM (1,1) method had the best prediction performance for monthly pork price time series.

thumbnail
Table 3. Comparison of predicted value and actual value from July 2020 to December 2020.

https://doi.org/10.1371/journal.pone.0251436.t003

Prediction

Census X12-GM(1,1) method was used to obtain the time series data of pork price in January 2021, February 2021 and March 2021 (Table 5). The forecast data showed that the price of pork would decrease significantly in the next six months.

thumbnail
Table 5. The predicted values of Census X12-GM(1,1) method from January 2021 to June 2021.

https://doi.org/10.1371/journal.pone.0251436.t005

Discussion

When the prediction results of multiple models was compared, some key information of other models was omitted. Next, the details of the other models will be shown.

When ARIMA model was used to fit the monthly pork price series, the normative modeling steps were carried out. Firstly, ADF (Augmented Dickey-Fuller test) was used to judge the stationarity of the original pork price series. After the first-order difference of the original series, the original pork price series met the requirements of stationarity. Next, ARIMA (0,1,1) and ARIMA (2,1,3) were created respectively according to the ACF (Autocorrelation Function) and PACF(Partial Autocorrelation Function) graph. Finally, by comprehensively judging the values of R2, AIC (Akaike Info Criterion) and SC (Schwarz Criterion), ARIMA (2,1,3) was chosen. Of course, the residual after fitting the original time series with ARIMA (2,1,3) model was also tested for correlation, the result showed that it was white noise.

The specific form of single GM (1,1) model used to directly fit the original monthly pork price time series was X(1)(k) = −768.93e−0.045(k−1) + 806.13. The post test ratio (c) and small error probability (P) of the model are acceptable.

Holt-winters model is a kind of exponential smoothing method for fitting time series, which can be subdivided into seasonless model, additive model and multiplicative model. According to the actual situation of the data, we used its multiplicative model.its parameter values were automatically set as α = 1, β = 0.34, γ = 0 by the Eviews software.

In the process of using Census X12-GM(1,1) method to forecast monthly pork price, we used a parameter which was called an empirical seasonal factor. This parameter comed from the results of many experiments. For other practice series, the seasonal factors may be different, so it should be judged again according to the historical data. Census X12-GM(1,1) method only predicted the pork price data in the next six months. This is because the pig breeding cycle is about six months. It is also feasible to use Census X12-GM(1,1) method for longer time prediction, but the longer the time, the worse the accuracy.

Conclusion

In this paper, several different methods were used to forecast monthly pork price data, including ARIMA model, GM (1,1) model, Holt winters model and Census X12-GM(1,1) method. By comparing RMSE, MAPE and MAE indexes, it was proved that Census X12-GM (1,1) method was more accurate. The prediction results of Census X12-GM(1,1) method can provide important reference for pig farmers, policy-making departments, middlemen and final consumers.

Supporting information

S1 File. The data of pork price from January 2014 to December 2020.

https://doi.org/10.1371/journal.pone.0251436.s001

(XLS)

Acknowledgments

We would like to thank the complex system simulation team of School of Management Engineering, Capital University of Economics and Business for their support and help in the use of professional software.

References

  1. 1. Hong Zhang, Fang Liu, Zhongwei He. Analysis and countermeasures of pork price fluctuation in China under African Swine Fever. China Journal of Agricultural Outlook. 2020;16(7):8–13.
  2. 2. Lixiang Zhang, Qianfeng Luo, Lei Han. Study on long term mechanism of sustainable development of pig industry in China. China Journal of Agricultural Economic Problems. 2020;12:50–60.
  3. 3. Gang Liu, Youming Yang. Research on the policy of meat market regulation in China. Price: Theory & Practice. 2020;07:40–43.
  4. 4. Bessler DA, Akleman DG. Farm prices, retail prices, and directed graphs: results for pork and beef. American Journal of Agricultural Economics. 1998;80(5):1144–1149.
  5. 5. Mengying Zhen. Breeding end of the slow pace of slaughter, pig market bullish mood spread. Swine Industry Science. 2020;37(12):16–17.
  6. 6. Box George E. P., Jenkins Gwilym M., Reinsel Gregory C., Ljung Greta M. Time series analysis: forecasting and control, 5th Edition. Hoboken, New Jersey: JOHN WILEY & SONS,INC.; 2015.
  7. 7. ZKolarik , Thomas , Rudorfer , Gottfried . Time series forecasting using neural networks. ACM Sigapl Apl Quote Quad. 1994;25(1):86–94.
  8. 8. Fawaz H I, Forestier G, Weber J, Idoumghar L, Muller P. Deep learning for time series classification: a review. Data Mining and Knowledge Discovery. 2019;33(4):917–963.
  9. 9. Jianxi Yang, Yingxin Zhou, Jianting Zhou, Yue Chen, et al. Prediction of bridge monitoring information chaotic using time series theory by multi-step BP and RBF neural networks. Intelligent Automation & Soft Computing. 2013;19(3):9305–314.
  10. 10. Tianhe Sun, Tieyan Zhang, Yun Teng, Zhe Chen, Jiakun Fang. Monthly electricity consumption forecasting method based on X12 and STL decomposition model in an integrated energy system. Mathematical Problems in Engineering. 2019;2019:16.
  11. 11. Bifang Li, Yangtian Wang, Yongbo Zhang. Research on the forecast of Heilongjiang retail sales under the seasonal adjustment of census X12. Statistics & Decision. 2010;04:123–125.
  12. 12. Zhanjun Qiao. Medium and long term load forecasting based on census X12-SARIMA model. Proceedings of the CSU-EPSA. 2014;26(1):34–38.
  13. 13. Pei Wu, Zhemin Li. Research on pork price forecast in China—Based on ARIMA-GM-RBF combination model. Price: Theory & Practice. 2019;01:75–78.
  14. 14. Haining Meng, Xinyu Tong, YueKai Shi, Lei Zhu, Kai Feng, Xinhong Hei. Cloud server aging prediction method based on ARIMA-RNN combined model. Journal on Communications. 2021;42(1):163–171.
  15. 15. peng Zhang. Improved ARIMA-GM-SVR combined forecasting model and its applicationl. Statistics & Decision. 2019;35(13):82–84.
  16. 16. Naichi Peng, ting Dang. Combined forecasting model based on ARIMA-GM-BP and its application. Statistics & Decision. 2016;02:80–82.
  17. 17. Erdal Kayacan, Baris Ulutas, Okyay Kaynak. Grey system theory-based models in time series prediction. Expert systems with applications. 2020;37(2):1784–1789.
  18. 18. Julong Deng. Control problems of grey systems. Systems & Control Letters. 1982;1(5):288–294.
  19. 19. Mingzhi Mao, Clive Chirwa Efford. Application of grey model GM (1, 1) to vehicle fatality risk estimation. Technological Forecasting and Social Change. 2006;73(5):588–605.
  20. 20. Jiwei Yuan, Zhongke Shi. A method of vehicle tracking based on GM (1,1). Control and Decision. 2006;21(3):300.
  21. 21. Guo-Dong Li, Daisuke Yamaguchi, Masatake Nagai. Application of GM (1, 1)-Markov chain combined model to China’s automobile industry. International Journal of Industrial and Systems Engineering. 2007;2(3):327–347.
  22. 22. Shuhua Man, Ye Chen, Xinping Xiao. City traffic flow prediction based on improved GM (1, 1) model. Journal of Grey System. 2012;24(4):337–346.
  23. 23. Wang YF. Predicting stock price using fuzzy grey prediction system. Expert systems with applications. 2002;22(1):33–38.
  24. 24. Liurui Deng, Zongyi Hu, Shenggang Yang, Yanyang Yan. Improved non-equidistant grey model GM (1,1) applied to the stock market. Journal of Grey System. 2012;15(4):189–194.
  25. 25. Yuting Jiang. Price forecast of winter jujube based on Grey GM (1,1) model. Scientific and Technological Innovation. 2019;18:17–18.
  26. 26. Yuqiong Liang, Jian Liang. Precipitation prediction test of GM (1,1) climate prediction system. Guangdong Meteorology. 2007;03:24–25.
  27. 27. Yong Yu, Qiong Wu, Bingqing Ding. Application of GM (1,1) model in national natural disaster prediction and evaluation project taking forest fire prediction as an example. Project Management Technology. 2017;14(03):24–26.
  28. 28. Wang YN, Wei FF, Sun CQ, Li QZ. The research of improved grey GM(1,1) model to predict the postprandial glucose in type 2 diabetes. BioMed Research International. 2016;2016:1–6. pmid:27314034
  29. 29. Ceylan Z, Bulkan S, Elevli S. Prediction of medical waste generation using SVR, GM (1, 1) and ARIMA models: a case study for megacity Istanbul. Journal of Environmental Health Science and Engineering.2020;18(2):687–697. pmid:33312594
  30. 30. Gao J, Li J, Wang M. Time series analysis of cumulative incidences of typhoid and paratyphoid fevers in China using both Grey and SARIMA models. PloS one. 2020;15(10):e0241217. pmid:33112899
  31. 31. Zhou J, Yang Q, Zhang X, Han C, Sun L. Traffic Prediction Method for GEO Satellites Combining ARIMA Model and Grey Model. Journal of Shanghai Jiaotong University (Science). 2020;25(1):65–69.
  32. 32. Liu L, Wu L. Holt–Winters model with grey generating operator and its application. Communications in Statistics-Theory and Methods. 2020;1–14.
  33. 33. Qiang Zeng, Xuesong Wang, Huiying Wen, Quan Yuan. An empirical investigation of the factors contributing to local-vehicle and non-local-vehicle crashes on freeway. Journal of Transportation Safety & Security. 2020;1–15.
  34. 34. Huiying Wen, Xuan Zhang, Qiang Zeng, N.N Sze. Bayesian spatial-temporal model for the main and interaction effects of roadway and weather characteristics on freeway crash incidence. Accident Analysis & Prevention. 2019;132;105249.
  35. 35. Wu L, Liu S, Yao L, et al. The effect of sample size on the grey system model. Applied Mathematical Modelling.2013;37(9):6577–6583.