VIETNAM NATIONAL UNIVERSITY HOCHIMINH CITY UNIVERSITY OF INFORMATION TECHNOLOGY ADVANCED PROGRAM IN INFORMATION SYSTEMS BACH HONG THAI - 17521311 DUONG LE THANH BINH - 17520279 BACHELOR OF ENGINEERING IN INFORMATION SYSTEMS THESIS ADVISOR CAO THI NHAN HO CHI MINH CITY, 2021 Assessment Committee The Assessment Committee is established under the Decision. by Rector of the University of Information Technology. ACKNOWLEDGMENTS We would like to express our sincere gratitude to our thesis director Dr. Cao Thi Nhan for her valuable time, outstanding guidance, insightful reviews, and valuable advice.
Without her commitment to our success, this work would not have been possible. She is a constant source of motivation and helps us sharpen our skills which were extremely useful when we worked on our thesis. In my innermost, we have a deep respect for her. In addition to expressing our gratitude to our supervisor, we are simultaneously grateful to my university, especially the Faculty of Information Systems.
Furthermore, we would like to show our appreciation to all teachers who have taught us for 4 years at The University of Information Technology. They set their heart on teaching their students, including us. Therefore, we really hold them in high esteem. TABLE OF CONTENTS ce Chaptrl PROBLEM STATEMENT.- G1 x1 90 ng nh ng nghe 1 1.2 Alm and ObJ€CfIV€S.
2 Chapter2 LITERATURE REVIEW AND THEORICAL BACKGROUND.1 Time-serles TechniQUe€S.--- -s + vn ng ng nưệt 3 2.- Ă HS HH kg 3 2.2 Machine Learning Modeling. Combining Statistical and Machine Learning Modeling .- cece ce «sàn HH, 10 24 Accuracy EVvaÏuatiOn.- xxx kg Hệ, 10 2.1 Scale Dependent MetrICS.- 55-5 Sc SE sseeeeeerseeeree 12 2.2 Percentage Error IMetTICS.c se rey 12 Chapter3 METHODS AND DATASEÏT. --- 5 - SH HH gieo 14 “nu.1 Extreme Gradient BOOSfINE.2 Long Short-Term MeImOrVy.2 Dataset and Data Integration.1 Be Cung Dafase(. Ăn HH HH kg tre, 26 3.2 Brazilian E-commerce by Olist Dafaset.3 Breakfast at the Frat Dafaset.4 Google Trends Search Index Data.5 Combining Google Trends Data with Real Data.
Experimental Machine Configuration .---- «<< «<< x+ss++ 52 Chapter4 EXPERIMENTTS.- -Ặ- SẶ HH HH HH HH ưệt 33 4.1 Breakfast at the Flat DafaSeT.2 Brazilian E-commerce DafaSe(.-- cv HH kh 67 ChapterS5 CONCLUSIONS2. HH TH HH kh 73 11 LIST OF FIGURES ce Figure 2.1 A bascic neural n€fWOTK. -- - - + + +13 vi srirereerrere 6 Figure 2.2 Time series forecast Error ÌMefTICS.1 Concept flow đ1aØTA.2 Layer of LSTM adapted from [27] .3 Structure of LSTM retrieved from [28] .4 Sale history of top 4 products categories in Becungshop.5 Time-series Cross- Validation of Becungshop dataset.6 The schema of Brazilian e-commerce by Olist Dataset.7 Distribution of order status in Brazilian e-commerce.8 Number purchases of customer in Brazilian e-commetce.9 Product orders in each state in Brazilian e-commerce.10 Map of product orders in each state in Brazilian e-commerce .11 Transaction count of each product category in Brazilian .12 Total payment value of each product category in Brazilian.13 Time-series Cross-Validation of Brazilian e-commerce dataset .14 The schema of Breakfast at Flat Dataset .15 The description of Product Lookup table in Breakfast at Flat.16 The description of Transaction Data table in Breakfast at Flat .17 The description of Store Lookup table in Breakfast at Flat.18 Store distribution at each state in Breakfast at Flat.19 Product categories distribution in Breakfast at Flat.20 Sale history of bag snacks at store in Breakfast at Flat.21 Sale history of cold cereal at store in Breakfast at Flat .22 Sale history of frozen pizza at store in Breakfast at Flat.23 Sale History of oral hygiene at store in Breakfast at Flat.24 Time-series Cross-Validation of Breakfast at Flat dataset .25 Google Trends’ user interface .1 Visualization in Ohio - Kell Frosted Flakes - XGBoost model.2 Feature importance of Kell frosted flakes at 2011-07-16.3 Visualization in Texas - Kell Frosted Flakes - LSTM model.4 Visualization of sports leisure - XGBoost model — Brazilian .5 Visualization of telephony - XGBoost model — Brazilian.6 Feature importance of telephony - 2018-05-20 — XGBoost.7 Visualization of sports leisure - LSTM model — Brazilian.8 Visualization of ‘Dam váy bé gai’ — XGBoost - Becungshop.9 Feature Importance of “Dam vay bé gái” at 2021-03-21 .10 Visualization of “Đồ bộ bé gai’ - LSTM model — Becungshop.11 The diagram of Becungshop .c:ccceesesceeeeceseceeeeseeeeeeaeeeneeaee xii Figure A.12 Description of columns Brazilian e-commerce by Olist Dataset.xv LIST OF TABLES ce Table 3.1 Description of experiment Models .-- 55555 s*++++se+se+ 15 Table 3.2 Hyperparameters configuration of XGBOOSE.3 Hyperparameters configuration of LSTTM.4 Number record of 4 famous product Caf€ØOT1©S.5 Table of input data after processing from Becungshop .6 Dataset summary in Becungshop.7 Number record of 5 famous product Caf€ØOTI€S.8 Table of input data after processing from Brazilian e-commerce.9 Dataset summary in Brazilian e-cOMMELCE «00. eee eee ete --«+<s+ 40 Table 3.10 Table of input data after processing from Breakfast at Flat.11 Dataset summary in Breakfast at FÏat.1 Performance Metrics — XGBoost - Breakfast at Flat - Exp 1 & 2.2 Performance Metrics - LSTM - Breakfast at the Flat - Exp 1 & 2 .3 Description of additional transaction data for Exp 3 & 4.4 Performance metrics — selected product-store - Exp 3 & 4.5 Performance metrics - XGBoost - Brazilian - Exp 1 & 2.6 Performance metrics — LSTM - Brazilian — Exp 1 & 2.7 Performance metrics - XGBoost - Becungshop — Exp 1 & 2.8 Performance metrics - LSTM - Becungshop — Exp 1 & 2.
70 vi ABSTRACT Most business organizations heavily depend on a knowledge base and demand prediction of sales trends. The accuracy in sales forecast provides a big impact on e- commerce especially in times of pandemic outbreaks around the world. People around the globe tend to shift to buying and selling on e-commerce platforms more. It also changes consumption and shopping habits.
Consumers prefer to shop online. During the peak of the epidemic in Viet Nam from April to August, this is the only channel to access some goods and services. That leads to strong growth in the e- commerce industry and its new challenges and opportunities. In order to prevent the possibility of product shortages of e-commerce enterprises and in addition to using traditional predictions to predict customer demand, this thesis proposes a method that combines with external data (especially is Google Trends) to improve sales prediction accuracy.
To analyze and compare the values in this thesis, we performed experiments on two algorithms are Extreme Gradient Boosting algorithm (XGBoost), and a recurrent neural network with long short-term memory (LSTM) with datasets from businesses like Becungshop, Brazilian e-commerce, and Breakfast at the Frat. Experimental results on a large number of real data sets show that, compared with traditional models, our proposed method has improved some scores of e- commerce forecasting models but is quite minor and should be improved in future research. Vil Chapter1 PROBLEM STATEMENT 1.1 Introduction The government in Viet Nam has imposed mandatory restrictions and enforced a temporary shutdown of stores and restaurants to limit the spread of the virus among citizens (Directive NO. Directive 16 mandates closures of non-essential businesses, restaurants, bans public gatherings and severely limits transportation services.
The shift toward e-commerce due to the COVID-19 pandemic has brought challenges to Viet Nam’s retail market and the global retail market and thereby shows the importance of the e-commerce industry. According to an IPSOS report [1], Vietnam is a country with a big shift from traditional shopping to buying on e- commerce websites. According to the Vietnam E-Business Index 2020 report, the average growth rate of e-commerce in the 2016-2019 period was about 30%. Accordingly, the scale of e-commerce retail of consumer goods and services increased from 4 billion USD in 2015 to about 11.5 billion USD in 2019.
According to the E-Business Report of Southeast Asia 2020 by Google [2], Vietnam e-commerce in 2020 increased by 16% and reached over 14 billion USD. As a challenge and opportunities in demand forecasting in 2021 besides pandemic. November 2021, Google continues to dominate the search engine industry with a 90,95 percent market share of search engines across Viet Nam and a market share of 91. Between November 2018 and November 2019, internet search traffic created 65 percent of worldwide e-commerce sessions.
Furthermore, research focusing on using internet search data in demand forecasting has developed. Google Trends search index data, for example, has been found to boost influence and have an impact on business results across a wide range of sectors. This thesis contributes to the field of knowledge by examining the predictive value of Google Trends in retail sales forecasting using modern machine learning techniques.2 Aim and Objectives This thesis aims to contribute to the knowledge of on time-series forecasting by comparing experiments using the Olist Brazilian E-commerce Public Dataset [4] and the dunnhumby Breakfast at the Frat public dataset [5], Becungshop private dataset to investigate the predictive power of Google Trends in forecasting retail sales. The objective of this thesis include: ¢ Using contemporary machine learning techniques, a methodological framework for incorporating external data in retail sales forecasting, namely Google Trends.
¢ Using 3 datasets which is Olists Brazilian E-commerce Public Dataset, Becungshop dataset, and dunnhumby's Breakfast at the Frat dataset to compare the predictive performance of the following models on sales forecasts: Extreme Gradient Boosting (XGBoost) and Recurrent neural network with long short-term memory (LSTM).3 Outline This thesis is divided into four sections. Literature review and theorical background will be discussed in Chapter 2. Then, we discuss about methods and dataset in Chapter 3. After that, experiments’ results are reported in Chapter 4, and the limits, conclusions, and prospects for future initiatives are provided in Chapter 5.
Chapter2 LITERATURE REVIEW AND THEORICAL BACKGROUND Nowadays forecasting with time series are coming from the idea that if you have knowledge about the past you can predict the future. Interpreting the past in terms of the future usually becomes the main idea of time series analysis.1 Time-series Techniques The importance of time-series when we look through decision maker’s perspective is the aptitude to deliver knowledge of value and information, upon which decision is made. The decision-making process is highly complex and has huge importance and it was researched throughout the years. When you want to make a decision, it is becoming gradually significant to have time-series prediction.
Nowadays best sources for time-serial are social networks, sales, different types, and they give excellent benefit to companies. To gain benefit it is also important to predict in a proper manner to get valuable awareness and the best way is to observe results from real-time and affluence of historic data generated through customer performances, processes of production. There are many different types of time series techniques, and an effective predicts needs to have a comprehensive understanding of them all. In each scenario, you should be able to identify not only which model will help the best answer the question at hand, but also which model is most appropriate for the data you are working with.1 Statistical Modeling Statistical modeling refers to the data science process of applying statistical analysis to datasets.
A statistical model is a mathematical relationship between one or more random variables and other non-random variables. The application of statistical modeling to raw data helps data scientists approach data analysis in a strategic manner, providing intuitive visualizations that aid in identifying relationships between variables and making predictions. The most common statistical modeling methods for analyzing this data are categorized as either supervised learning or unsupervised learning. Some popular statistical model examples include logistic regression, time-series, clustering, and decision trees.
Auto-Regressive Integrated Moving Average (ARIMA) model is the most widely used and accurate short-term time series forecasting method for univariate time series. The model holds that the current time sequence values are linearly related to the past time sequence values and the amount of external disturbance, that is, the model contains both autoregression item (AR) and moving average item (MA). The premise of ARMA is that the time series is stationary.