Research Article

Comparison Analysis of Different Time-Scale Heart Rate Variability Signals for Mental Workload Assessment in Human-Robot Interaction

Algorithm 2

Mental workload assessment after preprocessing.
Input:Multiple time-scale HRV segments for all subjects.
Output:Per-subject and cross-subject probability of mental workload.
1: For each time scale , .
2:  For each such that do
3:   Extract linear and nonlinear features for each signal at task-performing state.
4:   Extract linear and nonlinear features for each signal at relaxation state.
5:  End for
6:    If per-subject mental workload assessment
7:    For each such that do
8:     Train classifiers (SVM, KNN, LDA, GB, NB, and DT) based on the training set randomly selected from
   .
9:     Obtain the probability of mental workload based on the testing set , which is defined as .
10:   End for
11:  End if
12:  If cross-subject mental workload assessment
13:   Merge matrices , ,…, into one matrix .
14:   Merge matrices , ,…, into one matrix .
15:    Train machine learning method (SVM, KNN, LDA, GB, NB, and DT) based on the training set and
     randomly selected from and , respectively.
16:    Obtain probability of mental workload based on the testing set and , which are defined as and
    , respectively.
17:  End if
18: End for