Abstract
Brain-computer interface may be delineated as the merger of machine and software through which brain activity is allowed to govern a peripheral device or computer. The major aim is to aid a critically paralyzed person to live a normal healthy life. This arrangement passes over numerous stages which include data acquisition, feature extraction, data classification and control. The present work emphasizes the use of selective wavelet based features and classifies them using an artificial intelligence based technique namely support vector machine for wrist movement in four different directions. The data base used is the data set-3 of Brain-computer interface competition-4, which pertains to MEG signals acquired from two healthy subjects performing wrist movement in four different directions. The signal was processed using both wavelet packet transform and discrete wavelet transform and thereafter statistical features were extracted. The best discriminating features were selected after ranking all the extracted features using Principle component analysis. These features were then fed to the support vector machine based classifier for classification. The accuracy achieved is better than most reported in theliterature.
Introduction
Brain-computer interface (BCI) is a machine and software communication network enabling human to connect along with their surrounding using control signals which are generated by electroencephalographic (EEG) or Magnetoencephalographic (MEG) activity outside the requirement of an actual nerve pathway, hence creating a new non-muscular pathway for transmitting person intention to extrinsic equipment like a computer. BCI is highly advantageous for people suffering from neurodegenerative diseases such as Amyotrophic lateral sclerosis which influences the neurons in the brain making human mental activity impaired. The critical kind of impairment is locked in syndrome (LIS) in which a human is totally paralyzed [1]. During total LIS, a man loses command over the whole body such as eye movement, while in partial LIS a man can function to some extent as some part of the body retains control [2], whereas in classical LIS vertical eye movement is also possible as well. New applications and hardware have enabled the realization of people’s emotions, understanding and their psychology. The gradual development of these hardware as well as the software will enhance the accuracy of BCIsystem.
BCI setup recognizes the pattern of brain signal in five different stages that are data acquisition, preprocessing, feature extraction, classification and control [3]. In this paper, the data used pertains to MEG signals recorded from 2 healthy subjects performing actual hand movements. The data recorded will be processed to decode directional information encrypted within the trial MEG signals.
Signal acquisition
In order to garner information about the user’s intention, BCI relies on brain signals. At the recording stage, BCI measures the brain activity and the information are then translated into electrical signals. Different types of brain activity that can be monitored are Hemodynamic and Electrophysiological. Electrophysiological activities arise due to electrochemical transmitters which exchange information between neurons and are measured by EEG, MEG and the electrical signal acquired in single neurons. The Hemodynamic response is due to the release of glucose by blood to activate neuron at a higher rate as compared to the region of inactive neurons.
In the data set used, the electrophysiological activity of the brain for the subjects performing wrist movement was recorded through MEG. MEG is a non-invasive technique through which the brain activities are registered with the help of magnetic induction. Magnetic fields are produced on account of intracellular currents that are flowing through the dendrites and measured outside the head [4, 5]. Superconducting quantum interference device which is extremely sensitive to magnetic disturbances that are generated due to neural activity, is used to detect these magnetic fields [6].
BCI competition data set
The data set that has been used in our work pertains to BCI competition-4, data set-III [7] The data contains MEG signals that were recorded from two healthy right-handed subjects seated in MEG chair relaxed with their elbow on a pillow in order to prevent motion of upper arm and elbows. They were given a task to move the joystick that was initially at a central position to any of the four targets, radially located at an interval of 90° forming a rhombus. The amplitude of each movement was 4.5 cm. During every interval, the target was randomly chosen by the subject. Visual trigger signal was presented on screen which when set, the subject had to move the joystick from its initial central position to any 4 targets at the corner of the rhombus on horizontal plane indicating the position (right, forward, Left and backward) in order to validate the trial, the subject was asked to reach the target within 0.75 seconds and had to take rest for at least 1 second there. Data were obtained from the 10 MEG channels located above motor areas measuring brain activity during wrist movement at 625 Hz. Training data contained 160 trials 40 for each class namely right, forward, left and backward, for both subjects S1 and S2, and test data contained 74 and 73 test trials for subject S1 and S2 respectively. Each trials of 1 second were partitioned to contain data of 0.4 sec before and 0.6 sec after the movement onset. The signal was then band-pass filtered (0.5 to 100 Hz) and resampled at 400 Hz.
Fourier transform analysis is been used to convert the indigenous signal into frequency domain. Figure 1(a), (c), (e) and (g) illustrates the Fourier transform of one channel of subject-2 corresponding to all the four classes, showing the presence of power line artefacts of 50 Hz. Figure 1(b), (d), (f) and (h) shows the same signal respectively after filtering the power line artefacts using a Notch filter, moreover, observing the figures, it can be interpreted that for movement in different directions, the frequency pattern is different. Therefore, it can be used as a unique feature to analyze the activities.

The plot of Fourier transform depicting single channel corresponding to each class of subject S-2. The 50 Hz power line artefact can be seen clearly in the traces from (a) Right, (c) Left, (e) Forward & (g) Backward, while (b) Right, (d) Left, (f) Forward & (h) Backward shows the filtered signals for 50 Hz.
In our work, wavelet technique incorporating wavelet packet transform (WPT) and discrete wavelet transform (WPT) is used to extract feature. The major advantage of wavelet technique is that it breaks the signal into many components, therefore, allows multi-resolution analysis that enables to examine sets of information that may be hidden in raw signal. Wavelets also allow decimation in time and frequency simultaneously [8]. Continuous wavelet transform for a signal x (t) is obtained as
In which a and τ are scaling and shifting parameters, ψ is basic or mother wavelet which is given by
It is a convoluted task to calculate wavelet coefficient at every possible scale. On discretizing scaling and shifting factor as a = 2
j
and τ = 2
j
k the wavelet analysis gets computationally tractable. This is called as discrete wavelet transform (DWT) and is obtained for signal x (t) as
Where j and k ∈ Z (Z is an integer)
Figure 2 shows a 3-level filter bank for decomposition, where signals are split into sub-bands, each of these sub-band accompanies different frequency range information.

Three-level decomposition filter bank using (a) WPT and (b) DWT.
In DWT, signal is decomposed using low pass filter and high pass filter. The decomposed signal contains high-frequency content called detailed coefficient and low-frequency content termed approximate coefficient. The low-frequency content i.e. approximate coefficients are further decomposed at the next level by passing them through high pass and low pass filter.
Figure 2(a) illustrates a discrete wavelet transform based 3-level filter bank for decomposition. Here signals are split into sub-bands, each of these sub-band accompanies different frequency range information. In the figure, A signifies the approximate coefficients and D represents the detailed coefficients.In case of discrete wavelet transform, one-sided tree is formed where only the approximate coefficient is decomposed at each level while keeping the detailed coefficient intact.
In wavelet packet transform both approximate and detailed coefficient are decomposed at each level which forms a balanced binary tree. Wavelet packet offers more flexible analysis. Wavelet packet transform of the signal is illustrated in Fig. 2(b). In the present work Daubechies-4 (db4) mother wavelet has been used [8]. Figure 3(a) portrays the coefficients obtained after 3-level of decomposition using DWT of one channel for 10 trials, for subject-1, while in Fig. 3(b) packets of WPT of the same signal to third level of decomposition. These plots were obtained after bifurcating each trial to acquire section representing movement stateonly. (a). Plots of DWT Coefficients at third level. (b). Plots of wavelet packets at third level.
Different activities of an individual results in a different pattern of brain waveform. Being a pattern identification system, BCI categorizes each signal into a different class based on its characteristics.
BCI construe certain features that reflect similarity to a particular class and differentiates from other classes. These features are derivative of the signal containing higher distinguishing information required to make a line of demarcation between different classes. Some of the features that were computed on the wavelet coefficients and wavelet packets in our work are discussed below.
Energy
The energy of a signal is evaluated by squaring and summing of amplitude. It is given as
x i depicts the value of the input data and m is the complete samples and l is the decomposed level.
It is a computation of numerical distribution. IQR is more representative then standard deviation in case if there are outliers. It’s defined by
Q3 and Q1 are third and first quartile.
The variance may be defined as the mean of the square of deviation from the mean value leading to a proper measure of dispersion σ
i
, if
The NCV is calculated by evaluating the ratio of variance of epoch to the mean computed on absolute values as [10]
In order to effectively rank the extracted features for all the four classes, machine learning workbench Weka [11] is used.
Feature ranking results for both the subjects along with frequency range
The major purpose of classification in BCI system is to recognize subject’s intention from the feature vector that characterizes the brain activity. In order to achieve this goal, SVM classifier using Kernel Adatron is employed which is implemented through Neurosolutions [12]. SVM classifier constructs a set of the hyperplane that separates the feature vectors into several classes. The hyperplane is constructed such that there is the maximum margin between the neighbouring training data and the hyper plane [13]. The concept of SVM is to cast data into a high dimensional feature space and acquire a hyperplane that can split the class by the maximummargin [14]. 3D scatter plot depicting top-3 features as axis with 4 different class represented in different colors for Subject S-1.
SVM has been used for classification of the feature in binary [15] as well as in multi-class problem [16]. With the help of kernel function, it becomes feasible to produce SVM technique with non-linear decision-making boundary.
The advantage of non-linear SVM is that it guides to produce a more effective, moldable decision border in data space, thus improving classification accuracy. The best features that were obtained after ranking from the training data were used to train the classifier. Once the classifier was trained, features from the test dataset were fed to the classifier to determine the performance of the classifier. Figure 5 represents the pictorial representation of SVM architecture. The architecture of SVM using two class (circle and square) including optimal hyperplane separating the two class with maximum margin while the axis signifies the two dimensions (φ1 and φ2).
Classification results are given in the form of a confusion matrix which is used to compare between actual and predicted classification of MEG signals [17]. Sum of values corresponding to row and column (excluding true positive TP’s) gives a total number of false positive (FP’s) and false negative (FN’S) for a class. Accuracy from the confusion matrix was obtained by taking the ratio of the sum of correct classification to the total number of classifications.
Confusion Matrix
Confusion Matrix
Result obtained by different Researcher in the Literature
The data set-3 of BCI competition-4 comprises of 40 trials for training while 74 trials for subject-1 and 73 trials for subject-2 as test. Since, BCI system can effectively recognize user’s intention from the constructed feature vector, hence it is necessary to select highly distinguishable features. In this paper, statistical features based on discrete wavelet transform & wavelet packet transform were evaluated on the MEG signals, moreover, features obtained were ranked so as to select the best discriminating features for all the four classes namely right, forward, left & backward. The technique is computationally tractable and less expensive than the technique reported in other literatures. This work can be extended in future to enhance classification accuracy by using some more better discriminating features and other non-linear classifiers.
