## 4 Discussion  
In this study it was analyzed for the first time how different window length, sampling frequency, and feature set combinations affect the performance of physical recognition based on decision tree classifiers in order to optimize the classifier for real-time wearable systems. The results of this study have been implemented into a smart work-wear prototype [11]. The main findings were: (1) classification F1-scores with window lengths of 5 s and 3 s were similar, while results with 1 s were lower; (2) all sampling frequencies performed similarly for most activity types, with an exception of \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Activity Type** & **Window Length** & **Sampling Frequency (Hz)** & **Number of Features** & **F1 Score** \\ \hline \multirow{2}{*}{Static} & 5 & 25 & 110 & 0.97 \\  & 3 & 50 & 12 (SFS) & 0.98 \\ \hline \multirow{2}{*}{Low Intensity} & 5 & 13 & 110 & 0.93 \\  & 3 & 50 & 12 (SFS) & 0.97 \\ \hline \multirow{2}{*}{Moderate Intensity} & 5 & 50 & 110 & 0.90 \\  & 5 & 13 & 11 (SFS) & 0.91 \\ \hline \multirow{2}{*}{Rhythmical intensity} & 5 & 50 & 13 & 0.90 \\  & 5 & 25 & 12 (SFS) & 0.89 \\ \hline \multirow{2}{*}{Walking} & 3 & 50 & 43 & 0.98 \\  & 3 & 50 & 12 (SFS) & 0.98 \\ \hline \multirow{2}{*}{Running} & 3 & 25 & 13 & 0.99 \\  & 3 & 50 & 12 (SFS) & 0.99 \\ \hline \multirow{2}{*}{Outdoor Cycling} & 5 & 50 & 43 & 0.97 \\  & 3 & 50 & 12 (SFS) & 0.98 \\ \hline \multirow{2}{*}{Average} & 5 & 50 & 28 & 0.94 \\  & 3 & 50 & 12 (SFS) & 0.95 \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Parameter combination with highest F1-score for different activity types and the average for both feature reduction schemes. \begin{table}
\begin{tabular}{c c} \hline \hline
**Sampling Frequency and Window Length Combination** & **Number of Features in the SFS Feature Set** \\ \hline \multirow{2}{*}{50 Hz, 5 s} & 12 \\  & 50 Hz, 3 s & 12 \\  & 50 Hz, 1 s & 9 \\  & 25 Hz, 5 s & 11 \\  & 25 Hz, 3 s & 12 \\  & 13 Hz, 5 s & 11 \\  & 13 Hz, 3 s & 11 \\  & 13 Hz, 1 s & 14 \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Number of features in sequential feature selection (SFS) feature sets with different sampling frequencies and window lengths. outdoor cycling; (3) similar or better results were achieved with the feature sets with 9 to 14 features, achieved with either feature reduction scheme, compared to the initial full feature set of 110 features. The window lengths of 5 s, 3 s and 1 s were used in this study to analyze how different window lengths affect the performance of physical activity classifier. F1-scores of walking, running and low intensity activity types were similar to all window lengths, while the differences with moderate intensity, rhythmical intensity, and outdoor cycling were larger. Even though window lengths between 3 s and 1 s have been found to be suitable for other studies (2.56 s in [22], 2 s in [26], 1.5 s in [17], 1 s in [18]), in this study, the classifier performance had a larger drop when decreasing the classifier window down to 1 s, while window lengths of 5 s and 3 s had similar results. The window length of 1 s had statistically significant differences with both 3 s and 5 s window lengths while classifying static, moderate intensity rhythmical intensity and outdoor cycling activity types. This could be caused by 1 s window length not being long enough to capture the movement of the body during activities where one period of movement exceeds the window length. Different sampling frequencies of 50 Hz, 25 Hz, and 13 Hz were used to investigate how sampling frequency affects classification performance. For most classified activity types, no statistical differences were found between tested sampling frequencies, but there were large differences while classifying outdoor cycling. Previously, it had been found that frequencies above 20 Hz cannot be expected to arise from voluntary human movement, where the accelerometer is not in contact with vibrating external sources [20].