Analysis of Retail Sales Data Based on Special Days and Weekly Consumption Behaviors: A Python-Based Data Mining Approach
Main Article Content
Abstract
This study analyzes retail sales data based on special occasions and weekly consumer behavior using a Python-based data mining approach. The dataset comprises 5,297,513 transaction-level sales records from a local retail supermarket chain operating in Kayseri, Turkey, covering the years 2023 and 2024, as well as the first three months of 2025. The analysis was conducted using SQL Server Express and the Python programming language. The dataset used in this study consists of product groups divided into 25 main categories and a total of 62 subcategories associated with these main categories. The corresponding category structure is presented in Table 3 in the methodology section. Through time series analyses, sales fluctuations across days of the week and during special occasions were compared, and product sales contribution levels were identified using ABC classification. The findings reveal that certain products with high sales volumes on special occasions also maintain similar volumes on regular days; however, consumer behavior under specific conditions should be carefully evaluated. Furthermore, a noticeable increase in the sales of beverages and breakfast items was observed toward the end of the week, highlighting a recurring pattern that underscores the need for strategic planning in terms of promotional activities and inventory management. The results of the ABC analysis revealed that a small number of Class A products contributed significantly to total sales. These products were found to be primarily essential and frequently consumed items. Moreover, their sales contributions varied depending on store type and customer profile, suggesting that ABC classification should be conducted at the local level. Class B products demonstrated a moderate yet consistent sales volume. In contrast, although Class C products were numerous, their contribution to total sales was limited, and they were mostly concentrated in categories with a high level of variety. This situation indicates the need to reassess the product portfolio by taking into account sales performance, category structure, and customer orientation. By analyzing high-volume transaction data across days of the week, special occasions, and product categories, the study contributes to a better understanding of consumer behavior in the retail sector and supports the development of data-driven decision-making mechanisms. The findings are expected to provide valuable insights for campaign design, strategic planning, inventory management, and product portfolio optimization.
Article Details

This work is licensed under a Creative Commons Attribution 4.0 International License.