Monthly Prediction of the US retail and Food Services sales Published Monthly By the US Census Bureau with an Accuracy of ~97.76% Average

The Business & Economy topic is your portal to comprehensive information about the number, activity, characteristics, and locations of American businesses.

The Census Bureau has been collecting information about American businesses for over 200 years. Today, statistics on almost 27 million business locations are among the Nation’s most important. Business statistics are used to help start a business, compare industries and locations, assess the economic health of local communities, or just to make informed decisions.

What is a Predictive Analysis?

Predictive analysis is the process of making predictions based on past and present data and analyzing hidden trends or patterns in the data. In other words, it’s a method of discovering future events or predicting future sales before it happens. This is not a new concept, but with the help and popularity of Python, a high-level interpreted general-purpose language, and its rich host of numerous libraries, such as Sklearn, Pandas, Matplotlib, Numpy and others, anyone fascinated with Machine Learning and Artificial Intelligence (AI) can develop a predictive model.

A practical example is a meteorologist who predicts weather by forecasting expected weather outcomes based on past and present data by analyzing trends using a predictive model. However, this might not be 100% accurate, but with a high accuracy rate. Let’s look into some practical areas where I have tested some predicted models developed using Python, Sklearn, Mathplotlib, Pandas, Numpy, Seaborn, and other libraries.

I’m very fascinated with technology and have spent a great amount of time studying and practicing the machine learning concept. However, it’s equally important to put some of that self-taught knowledge into a real-life problem to determine how well this model can perform in production. There are various types of machine learning models, depending on the problem one would like to solve – this will determine the type of machine learning model to solve that specific problem.

Predictive models can be used in the health sector to predict the likelihood of someone having a heart attack, by selecting appropriate features to achieve a high performance. Irrelevant or partially relevant features can negatively impact model performance. For binary outcome (Yes/No output), a Logistic Regression model will be appropriate using given factors to determine if a patient will likely have a heart attack or not.

In the banking sector, predictive models can be used to predict someone that would most likely default on credit card payment. Predictive models are used in the bank sector to protect banks from issuing a credit card to someone that their model deemed most likely to default on repayment. The business sector uses predictive models to determine future sales and other future events, such as the number of returning customers or revenue forecast. In the process of developing a prediction model, there are critical steps necessary to get optimal performance. Machine Learning algorithms and Artificial intelligence lifeline is data, the more accurate and refined data available the more optimal performance one can get from machine learning algorithms. However, in real life, perfect data is impossible, as most data scientists and machine learning engineers spend most of their time in data wrangling or data cleaning before that data can be useful and ready for the training and testing process of the model. Overfitting and underfitting are also very important to avoid bias in trained model.

How does Machine Learning Model Works?

To develop a machine learning model, there must be data from the previous activities or transactions data. Those data will be used to training/test and fit the model to predict future results, if the model is given new data that it has not seen before. When new data is present to the model to predict on those new data, the trained model will perform prediction based on the previously train, test, and fit method.

A Practical Example of How Machine Learning Algorithms Were Tested Against Future Data

I developed a machine learning model in April 2020 to predict the monthly U.S retail sales published monthly by the U.S Census Bureau. The overall performance of this model has been an average of 95.4% accuracy, which is pretty good in predicting the real-life U.S monthly sales. I compared the actual figures from the US monthly retail sales to my trained model and the results were very impressive. I have been testing this model every month and overall performance seems astonishing, see the graph in the next page.

  • Report posted monthly by the U.S Census Bureau between 15 & 17 each month
  • Retail sales report a strong indicator of economy health determine if contracting or expanding
  • Retail sales in terms of direct economic activity account for almost one-third of GDP
  • Used by the Labor and Statistics Bureau to calculate Consumer Price Indices and productivity measurements
MonthActualPredictionDiff (Pred – Act)Percentage Accuracy
April 2020403,946398,821-5,12598.73%
May 2020485,545382,152-103,39378.71%
June 2020524,306456,695-67,61187.10%
July 2020535,982528,345-7,63798.58%
August 2020537,526525,885-11,64197.83%
September 2020549,256535,695-13,56197.53%
October 2020553,329481,220-72,10986.97%
November 2020546,504585,08838,584107.06%
December 2020540,916563,47522,559104.17%
January 2021568,215529,616-38,59993.21%
February 2021561,685568,8917,206101.28%
March 2021619,105563,898-55,20791.08%
April 2021619,923619,556-36799.94%
May 2021620,214620,088-12699.98%
June 2021621,340606,525-14,81597.62%
July 2021617,719624,2976,578101.06%
August 2021618,676619,310634100.10%
September 2021625,416620,271-5,14599.18%
October 2021638,189627,038-11,15198.25%
November 2021639,829639,86334100.01%
December 2021626,833641,51014,677102.34%
January 2022649,776628,418-21,35896.71%
February 2022658,128651,455-6,67398.99%
March 2022665,726659,841-5,88599.12%
April 2022677,711667,470-10,24198.49%
May 2022672,874679,5046,630100.99%
June 2022680,591668,366-12,22598.20%
July 2022682,815682,395-42099.94%
August 2022683,291684,6281,337100.20%
September 2022683,974680,317-3,65799.47%
October 2022694,518685,792-8,72698.74%
November 2022693,482696,3792,897100.42%
December 2022677,136695,33918,203102.69%
January 2023
Link to the Bureau of Labor Statistics

Similar Posts