# Personalized Advertising in E-Commerce: Using Clickstream Data to Target High-Value Customers
## 4 Experimental Results for Validating Proposed Algorithm  
Targeted advertising is challenging to define due to various factors that influence it. Nevertheless, e-shops set their advertising budgets based on historical data or consultant advice. It is widely accepted that targeted advertising has a positive impact. The effectiveness of ad campaigns and our proposed algorithm to boost e-commerce sales and reduce advertising cost is experimentally tested on two different Lithuanian e-commerce websites (A and B) characterized by distinct daily visitor counts and varied numbers of visited webpages. The website A specializes in a comprehensive range of cutting-edge computer and household appliances, offering customers the latest technology and innovative solutions for their homes. E-Shop B stands out as a go-to destination for computer and household appliances, featuring a diverse selection that caters to various needs, from high-performance computing devices to modern home essentials. The website A receives approximately 40 while website B has around 20 thousand visitors per day. The approximate daily number of items in clickstream data files are correspondingly 460 and 180 thousand. The analysis performed is based on data from 8 trading days, dealing with more than 4500 thousand clickstream records. Personalized data for this study was generously provided by the e-commerce platforms. The choice of an 8-day research window was guided by the necessity to ensure a minimum of 7 days for the comprehensive evaluation of visited weblinks weights, specifically focusing on days characterized by typical trade turnover. Original clickstream data was collected in comma delimited files-one file for one day. The variables collected in this file are: pixel--record identification, user--customer ID, data -link accessed, time--Unix timestamp, referrer--previous site link and device--device used. The example of data used is presented in Table 2.  
All calculations were done by using EXCEL and Python 3.8.10 64-bit software. The aim of this experiment is to identify dependencies in weblinks weights distributions used to compute the CM index values and the selection of limit value L to target customer groups for advertising campaigns between the two websites. We start with some statistical characteristics of websites A and B, including the average number of links per day visited by customers, are presented in Table 3.  
Based on the data presented in Table 3, it can be observed that e-shop A has more than 2 times as many visiting customers compared to e-shop B. The percentage of customers who make a purchase is similar between the two e-shops. However, customers of e-shop A tend to use the shopping basket twice as often compared to those of e-shop B. This suggests that e-shop A has a lot of unused resources in convincing the customer to pay for the items placed in the cart. Additionally, the average duration of time spent by surfers on site A is twice as long as that of site B. This may be the case if the e-shop A provides a lot of information on one page, or the information provided is quite complicated. Overall, the results suggest that e-shop A has a larger and more engaged customer base, with customers spending more time on the website and using the shopping basket feature more frequently. Meanwhile, e-shop B has a smaller customer base with less engagement. Next, we will try to calculate the dynamics of the customer's index CM and select members appropriate for behaviorally-targeted advertising campaign. First, using the procedure described in Appendix A, we estimate the weights of visited links separately for each e-store A and B. The results of calculation are given on the Table 4.  
These results show that the weights assigned to visited links Group of items and Specific item in e-shop A is more than twice lower than for e-shops B links. This mean that in e-shop A, these links are often opened without going to the shopping basket or checkout page.