Neuromarketing Solutions based on EEG Signal Analysis using Machine Learning

Marketing campaigns that promote and market various consumer products are a well-known strategy for increasing sales and market awareness. This simply means the profit of a manufacturing unit would increase. "Neuromarketing" refers to the use of unconscious mechanisms to determine customer preferences for decision-making and behavior prediction. In this work, a predictive modeling method is proposed for recognizing product consumer preferences to online (E-commerce) products as “Likes” and “Dislikes”. Volunteers of various ages were exposed to a variety of consumer products, and their EEG signals and product preferences were recorded. Artificial Neural Networks and other classifiers such as Logistic Regression, Decision Tree Classifier, K-Nearest Neighbors, and Support Vector Machine were used to perform product-wise and subject-wise classification using a user-independent testing method. Though, the subject-wise classification results were relatively low with artificial neural networks (ANN) achieving 50.40 percent and k-Nearest Neighbors achieving 60.89 percent. Furthermore, the results of product-wise classification were relatively higher with 81.23 percent using Artificial Neural Networks and 80.38 percent using Support Vector Machine. Keywords—Electroencephalogram (EEG); brain-computer interface; neuromarketing; machine learning; artificial neural networks


I. INTRODUCTION
E-commerce is a growing field these days. People want to expand their businesses, so they spend money on marketing to learn about their customers' preferences. Neuromarketing is a developing field with enormous potential for application marketing, brand management, and advertising. It emerges as a result of combining relevant concepts from the fields of neural science, psychology, human neurophysiology and even neuro chemistry. It connects consumer behaviour research with neuroscience [1]. Consumer behaviour quite often undermines the effectiveness of traditional marketing methods. This is because the consumers' reactions vary when they are exposed to advertisements. Neuromarketing is the key to gaining insight into the minds of consumers. Because neuromarketing does not necessitates the consumer's conscious participation. It operates on the unconscious state of the brain.
Neuromarketing assesses the brain's reaction to any advertising stimuli. It differs from self-reports that consumers provide during surveys. The truth can be revealed by studying the EEG signals directly [21]. As several reported studies show those two systems-conscious and subconscious can provide contradictory interpretations at times. Individual choices influence the decision-making process not only through individual and cognitive assessments, such as questionnaire responses but also through objective and implicit assessments, such as eye movement and neural activities. Recent findings from functional magnetic resonance imaging (fMRI) and EEG studies have linked movements in the frontal theta and posterior gamma bands to the development of individual choice. These findings show that before deliberate decision making, the physical reaction is caused by implicit desires. As a result, such neural behaviors associated with attention-related tasks, such as eye moments, can influence the consumer's preferences at an unconscious level. Despite this, there have been few neurological studies on the relationship between visual attention and subjective interest: the causes of subjective preference choices, such as the amount of visual perception and attention, are impossible to assess when using attractive faces with a wide range of visual features (e.g., facial contour, eye color, and hair length) [2].
Several commercial efficacy metrics can be calculated using neuromarketing. Emotional commitment, memory retention, purchase purpose, novelty, perception, and attention are the factors to consider. When customers make decisions, they are influenced by their emotions. The emotional interest level causes the emotional commitment level to rise. It can also help predict when customers will purchase by observing how their brains react to advertising stimuli. When customers decide to buy a product, the level of encoding of marketing stimuli influences our decision [3].
Neuromarketing provides knowledge that traditional marketing methods cannot provide. The significant advantage provided by neuromarketing techniques is that these techniques, which collect quantitative data, could be used before the launch of a new product, increasing the likelihood of that product's success [3].
Electroencephalography (EEG) was developed to record brain signals. EEG is used to study brain activity by recording postsynaptic potentials generated by neurons. With the development of tools, EEG is no longer limited to medical applications but has now been extended to other fields. Medical, Brain-Computer Interface (BCI), and neuromarketing are examples of EEG applications [4]. In the 298 | P a g e www.ijacsa.thesai.org [10][11], the authors have proposed a predictive modeling method based on EEG signals to understand customer preferences for E-commerce products in terms of "likes" and "dislikes". EEG signals were recorded while volunteers of various ages and gender browsed through various consumer goods. The tests were performed on a dataset containing a variety of consumer goods. The accuracy of choice prediction was calculated using a user-independent testing approach and hidden Markov Model (HMM) classifier. The prediction results appear to be promising, and the methodology can be used to create business models [11].
In comparison to the previous study, this study introduces subject-wise classification as well. The previous study has only done on the product-wise classification. The goal of this study is to assist marketing researchers in making appropriate decisions for further increasing the sale of products using imaging techniques by developing an EEG-enabled model that can replace expensive methods of current day neuromarketing. In addition, by analyzing EEG signals, a Neuro-marketing system will be provided to predict customer choices while viewing E-commerce products.
As such, the main objective of this study is to investigate the various tuning of artificial neural networks and other classifiers for improving the classification rates of productwise classification and for the first time doing subject-wise classification. Section II presents the background and related works in the field of neuromarketing. Section III presents our approach towards building an EEG-based prediction model. Section IV presents the results of our study and Section V concludes the paper with possible future recommendations.

II. RELATED WORK
We looked at recent studies that linked EEG signals to predict customers' response, behavior and emotions based on self-reported ratings. All these studies mostly focus on studying the relationship between brain imaging and customer decision-making. Kumar, Singh, et al. (2015) investigated the current state of neuromarketing, as well as the activities involved, which included neuroimaging, EEG, fMRI, and eyetracking. The customer dialectic is examined in the paper: "consumers contradict themselves, saying what they want but doing what they feel." The authors focused on four aspects of consumers: physical body, mind, heart, and spirit [5].
W. Anderson, Sijercic et al. (2007) worked on the classification of EEG Signals from four subjects while performing five mental tasks. Half-second segments of sixchannel EEG data were trained to be graded into one of five groups, each of which corresponds to one of five cognitive tasks completed by four subjects. Two and three-layer feed forward neural networks were trained using 10-fold crossvalidation and early stopping to avoid over fitting. To represent EEG signals, autoregressive (AR) models were used. The average percentage of correctly classified test segments ranged from 71% for one subject to 38% for another. The Clustering of the hidden-unit weight vectors of the resulting neural networks shows which EEG channels were most important in this discrimination problem [6,20]. Solhjoo, Nasrabadi, Golpayegani, et al. (2005) investigated chaotic signal classification using hmm classifiers and EEGbased mental task classification. The analysis of mental activities using brain signals, based on EEG provides a better understanding of human brain functions. Furthermore, the author stated for EEG chaotic signals it is critical to determine whether probabilistic and statistical signal processing tools (such as HMM-based classifiers) can handle chaotic signals. The author has examined how well HMMs perform in classifying various types of synthetically formed chaotic signals. The performance of such classifiers in classifying mental tasks based on EEG was then evaluated. The results in both cases indicate good performance [7]. Guo et al. (2013) developed the new recommender system for 3D e-commerce using EEG signals. The author proposed a novel augmented reality recommender framework for the world of e-commerce. The system makes recommendations based on customer preferences, taking into account both prepurchase and post-purchase scores, as well as post-purchase ratings in general. Positive emotions among users are evaluated using EEG signals before interacting with 3D virtual products. Pre purchase ratings work in tandem with postpurchase ratings to address two major challenges that traditional recommender systems face: data and cold start. By properly utilizing both pre-and post-purchase scores, user preference can be more reliably modeled. The author claimed that it has boosted the effectiveness of modern recommender systems and force traditional ecommerce applications to adapt [8].
The authors of [9] conducted an experiment on EEG signal classification using the wavelet transform. The author used an artificial neural network (ANN) technique in conjunction with a feature extraction technique, namely the wavelet transform. The artificial neural network used to classify the data is a feed-forward network with three layers that implements the back propagation algorithm for error learning. After that, the network with wavelet coefficients was trained. Over 66% of the normal class was correctly graded, and 71 % of EEGs in the schizophrenia group were positive. Murugappan, Celestin Gerard et al. (2014), the goal of their research is to use wireless EEG signals to identify the most popular automotive brand in Malaysia. This work is taken into account a community of four major vehicle brand advertisements, including Toyota, Audi, Proton, and Suzuki. The participants (9 male and 3 female, ages 22-24) were simulated using a 14 channel wireless Emotive headset with a sampling frequency of 128 Hz, and the brain activity responses to the stimuli were obtained using a 14 channel wireless Emotive headset with a sampling frequency of 128 Hz. The obtained signals are filtered using a Surface Laplacian filter and a 4th order Butterworth band pass filter with a cutoff frequency of 0.5 Hz -60 Hz is used to filter the obtained signals. The alpha frequency band (8 Hz -13 Hz) of EEG signal information was obtained using the same Butterworth 4th order filter. The Fast Fourier Transform (FFT) was used to extract three statistical features from EEG signals using the Alpha band frequency spectrum: power spectral density (PSD), spectral energy (SE), and spectral centroid (SC). The feature vector is constructed using extracted features extracted 299 | P a g e www.ijacsa.thesai.org from all of the subjects via four different advertising stimuli. This feature vector is fed into two non-linear classifiers, K Nearest Neighbor (KNN) and Probabilistic Neural Network (PNN), to classify the subject's intention on advertising [10].

III. SYSTEM SETUP
In this study EEG signals were recorded from 15 healthy people using a Muse 2 headset -which is a neuro-signal acquisition wireless device -connected to a mobile app called Muse Monitor, as shown in Fig. 1. The device has 4 channels for EEG data that are located at AF7, AF8, TP9, and TP10 positions as per the International 10 -20 system. Internally Muse 2 headband is sampled at a frequency of 256 Hz. The EEG data is stored in a CSV file and then transferred to computer for further processing. EEG headset was mounted onto the head of participants and asked to view shopping products as shown in Fig. 4.
We recorded 450 EEG signals, each lasting 4 seconds. Because the Muse 2 device has four sensors, it is the most user-friendly data acquisition device. We get raw data from four sensors. Fig. 2 shows the raw signal from AF7 Channel. Fig. 3 is the graph of RAW signals from AF7, AF8, TP9 and TP10 sensors. Fig. 4 shows the products we have used. While the user was viewing an item EEG signals were collected simultaneously. After the watching, each consumer was asked to rate the product in one of two categories: like or dislike. Then the signal passes through certain signal pre-processing techniques and feature extraction steps. Next, classification models are built, trained, and tested based on the user's choice.

A. Data Preprocessing and Feature Extraction
Pre-processing is the necessary step in EEG processing because it converts the signal into a usable format. The Initial pre-processing was done in excel to ensure that each recording was exactly 4 seconds long. Fig. 3 shows the unfiltered raw EEG signals from different channels: AF7, AF8, TP9 and TP10.

B. S-GOLAY Filter
Researchers have successfully used the S-Golay filter in signal smoothing. It is implemented using least squares or polynomials to reduce the noise in signals and smooth them out by fitting consecutive sub-sets of neighboring signal points with low-degree polynomials and linear least squares. The S-G filter has two parameters: polynomial degree and frame size. PRO and SNR (signal to noise ratio) is the output evaluating variables for denoising EEG signals using the S-G filter. The experiment results show which type of polynomial degree value is best [13].
The S-Golay filter can be applied to obtain a smoothed signal for a signal S j = f (t j ), where (j=1, 2,…., n) with length of n as mathematically defined below.
Where m is defined as frame span, c i represents convolutional coefficients number and Q j is the smoothed output signal. Fig. 4 depicts the RAW signal from a single channel, while Fig. 5 depicts the smooth signal after applying the S-Golay filter.

C. Wavelet Transform Wavelet Transform (DWT) based Features
The most important part of distinguishing objects from one class to another is feature extraction. It is the process of converting raw signals into useful features. It is required to proceed to the next steps. For the classification of the EEG signal, we used discrete wavelet transform (DWT) [14] based on features. The DWT typically produces five signals: alpha, beta, theta, gamma, and delta bands of varying frequencies.
Eq. 2 provides a mathematical explanation of DWT.
When S is used as a scaling factor, it is usually set to 2. DWT is commonly used in biomedical signal processing because it denotes a signal in the time and frequency domains. The basic idea, behind DWT, is to use multistage decomposition to transform the signal input signals into small waves. A signal's wavelet analysis based on transformation can be performed at different frequency bands by decomposing it into approximation (A) and information (D) coefficients. To begin, two digital filters, the Low Pass Filter (L) and the High Pass Filter (H) are used to process the signal (H). A low-pass filter (L) is applied to the signal, which eliminates high-frequency fluctuations while preserving slow patterns.

D. Classification
Following the feature extraction step, we used those features for classification. Support Vector Machine (SVM) [15], Logistic Regression [16], Decision Tree [17], Random Forest [18], and Artificial Neural Networks [1 9] are among the classifiers employed. These features were classified subject-wise as well as product-wise on different bands. The dataset were divided into training and testing sets, with 80 percent of our data used for model training and 20 percent used for model testing.

IV. RESULTS AND DISCUSSION
As the features are fed into the Artificial Neural Network, various classifiers such as SVM, LDA, Logistic Regression, Random Forest, and Decision Tree are employed. The following are the ANN results.

A. Subject Wise Classification
We used 14 subjects in our experiment to collect EEG data from them while they are watching and selecting the products, and a K-fold cross validation of 10 folds was used to validate our experimental results. Different models are trained and accuracies are obtained using 5 different bands: alpha, beta, theta, gamma, and delta. These accuracies are evaluated for each product separately to carry out subject-wise classification.

B. Hyper Parameter Tuning on Theta Band for Model
Selection ANN is trained on 14 subjects using theta band with columns named Theta AF7, Theta AF8, Theta TP9, and Theta TP1 0. Table I displays the tuning of the ANN model's model parameters. To achieve the best results, the hidden layers, the number of neurons, activation function on layers, and optimizer are all varied. As a result, the number of hidden layers should be one and the number of neurons should be two to achieve the best result of 50.40 percent for theta band.
ANN Model is trained using theta, alpha, beta, gamma, and delta bands using 10 folds on 14 subjects. Different parameters of ANN models have been tuned to achieve the best overall accuracy for each band.
Subject-wise accuracy of 50.40 percent, 50.02 percent, 50.39 percent, '50.14 percent, and 50.21 percent is obtained using Artificial Neural Networks on the Theta band, Alpha band, Beta band, Gamma band, and Delta band, as shown in Table II by testing different classifiers to obtain the best subject-wise accuracy. Using Decision Tree, K-nearest Neighbors, and Logistic Regression, we achieve the highest accuracy on the Delta band of 57.30 percent, 60.89 percent, and 51.34 percent, respectively. Hence, K-nearest neighbors proved to be best algorithm for classification of the Delta band signals. Fig. 6 shows the accuracy of theta band tested number of times. Fig. 7 shows the maximum attained accuracy by alpha band is 51.5 %. Fig. 8 illustrates the minimum accuracy for beta band is 49.2 % and maximum accuracy is 50.5 %. Fig. 9 and Fig. 10 depict that minimum accuracy for delta and gamma band almost same that is 45.5 % with having maximum accuracy of 52 %.    302 | P a g e www.ijacsa.thesai.org

C. Product Wise Classification
The K-fold cross validation with 10 folds is applied for the product as well as subject-wise classification. Training and testing accuracies are obtained for various models using five different bands: alpha, beta, theta, gamma, and delta. Fig. 11 depicts the accuracy graph of the ANN model, which was trained using 14 products 1 subject. The model has learned completely after 15 epochs.
As shown in Table III, the average product-wise results are obtained accuracy of 78.73 percent,76.14 percent, 81 .23 percent, 74.12 percent, and 82.19 percent on the Alpha band, Theta band, Beta band, Gamma band, and Delta band using Artificial Neural Networks. To achieve product-specific accuracy, a variety of classifiers have been used.
The highest accuracy on the Delta band is 90.71 percent, followed by 92.21 percent, 82.37 percent, and 83.51 percent using Decision Tree, K-nearest Neighbors, Logistic Regression, and Support Vector Machine (SVM), as shown in Fig. 12. In our study, SVM and ANN performed better than in the previous study [11], and the results obtained are good enough to be used for practical business models.

D. HEAT Map
The proposed physiological heat map tool allows for the representation of the relative distribution of physiologically inferred emotional or cognitive states of users on a given interface. To make a heat map in MATLAB-based EEGLAB, first select the channel location, then perform the independent component analysis (ICA), and finally plot a 3D component map. Fig. 13 illustrates the 3D heat maps for a consumer's choices. This figure clearly depicts the difference in the heat maps for products with "like" and "dislike". The EEG signals for like are mainly concentrated on the right hemisphere while that for dislike are concentrated on the left hemisphere of the brain.

E. ICA (Independent Component Analysis) Component
The independent components analysis generates a set of weights for all electrodes such that each component is a weighted sum of operation at all electrodes, and the weights are designed to isolate brain electrical signal sources. Components with blink artifacts are possibly the easiest to detect. We have taken a careful approach and only deleted components from the data if you were confident they contained artifacts or noise with no or very little signal. ICA can be used to clean data, separate objects, and exclude certain components from the data, or reduce data. When the individual component analysis is used as a preprocessing method, components can be judged as containing objects based on their topographies, time courses, and frequency spectra. ICA also helps in removing high frequency noise from the EEG signal.

F. Discussion
In this work, we used EEG data to predict users' product preference using neuroscience. The outcome demonstrates the efficacy of the proposed framework and offers an additional option to existing methods of predicting product market success. This study investigates and improves the classification accuracies of subject-wise and product wise choice preferences. From results it is evident that our proposed system gives classification accuracy of up to 92.21 percent on the Delta band. The classification accuracies for all five bands are calculated both subject-wise and product-wise. Because there is more randomness in EEG signals of subjects, productwise accuracy is higher than subject-wise accuracy because EEG signals of the same products are more similar and accurate. The other strong point is that our neuromarketing tool is simple, as we used four dry electrode sensors that can be easily placed on the forehead.

V. CONCLUSION
Using EEG signals, we predicted a customer's product selection preference. The brain activity of 14 participants was recorded while they were viewing products. The Muse 2 headset, which has four sensors, was used to record EEG signals. Further, the filters were applied to make signals smooth and classified using Artificial Neural Networks and other classifiers like SVM, decision tree, logistic regression, and K-Nearest Neighbors. Using all of the above-mentioned classifiers, we obtained subject-and product-level accuracies. Our obtained results demonstrate the effectiveness of the proposed framework, which has provided a superior solution than traditional methods of predicting product success in the market. By extending existing models, the framework can aid in the development of market strategies, research, and forecasting market success.
In the future, this work can be extended by analyzing fictitious responses to product preferences as compared to neutral responses. To improve prediction results, more powerful features and algorithm combinations could be, developed.