5.2 Distributed Deployment on Storm
6.1.3 CDMC Framework Evaluation
The collective dynamical modeling clustering algorithm was used for clustering, with semi-Markov chain models as the dynamical models. Initial cluster guesses were com- puted by deviation-based DTW clustering as described in Algorithm 4, with either gwDTW (Equation 2.5) or sdDTW (Equation 2.6) as the distance metric. Clustering driven by the standard DTW (Equation 2.4) distance metric was used as a basis for comparison.
Clusters Quality: Due to the long average duration of a given stage in human sleep, it is better to explicitly describe its distribution of the sleep stage. In contrast with the expo- nential one (as shown in Figure 3.6) in hidden Markov models (HMM), Figure 6.3 illus- trates the CDMC clustering results for the semi-Markov dynamical models with Weibull state durations over 100 randomly chosen instances in the human sleep data. The coordi- nates of each instance are the estimated parameter values of the Weibull distribution for that instance’s wake duration distribution. Cluster centroids are significantly separated along both parameter axes (p < 0.05). The resultant two-sample t-test over coordinates of clustered instances in Table 6.1 of instances proves the significantly difference of sep- arating those two clusters in Figure 6.3.
Table 6.1: T-test of coordinates on human sleep dataset.
H value P value Param1 1 0.0017 Param2 1 0.0092
Models Analysis: Generative negative log likelihood was used to measure the qual- ity of model fit for unsupervised clustering. Given a dynamical model, M, built over a
6.1 HUMAN SLEEP PATTERNS 0.5 1 1.5 2 2.5 3 3.5 −0.8 −0.2 0.4 log(scale) log(shape)
Figure 6.3: Visualization of CDMC clustering of human sleep data with Weibull semi- Markov dynamical model. Coordinates of each instance are parameter values of wake stage Weibull model fit individually to the instance.
group of sequences such as human sleep sequences, the generative negative log-likelihood −log(P(s|M)) of a sequence, s, is a measure of the probability that the sequence, s, would be produced by the model, M. Lower negative log-likelihood values (higher generative probabilities) imply a better model fit. The goal of clustering was to minimize the genera- tive negative log likelihood. Comparison of median negative log likelihoods for different models was measured by a Wilcoxon rank sum test as described in section 2.4.
To investigate the importance of models in analyzing data, the human sleep data (WNR version) were clustered using CDMC with two clusters, for each of three dy- namical model types: semi-Markov chains with Weibull state durations , hidden Markov models, and Markov chains. Three-state chains were used in all cases. The genera- tive negative log-likelihood −log(P(s|M)) was used to measure the quality of model fit. Figure 6.4 shows the results. The median negative log-likelihood of the semi-Markov version is significantly better than that of the Markov chain version (p < 0.05, Wilcoxon-
Mann-Whitney test). Comparison of the semi-Markov version of CDMC against a hidden Markov model version also resulted in superior performance of the semi-Markov version (p < 0.05). SMM HMM 0 50 100 150 200 250 300 350 400 − log(P(s|M)) (a) SMM VS. HMM SMM MM 0 50 100 150 200 250 300 350 400 450 − log(P(s|M)) (b) SMM VS. MM
Figure 6.4: Negative generative log-likelihoods of CDMC clusters for semi-Markov (left) and hidden Markov (right) dynamical models in Figure 6.4(a), as well as semi-Markov (left) and standard Markov dynamical models (right) in Figure 6.4(b). Non-overlapping notches indicate significant difference in medians (p < 0.05). Semi-Markov models provide signifi- cantly better log-likelihood than other two models.
To fully examine dynamical models and various versions of hypnograms described in section 6.1.1, three Markov models were respectively tested in pairs as dynamical models in the CDMC framework. The t-tests of generative log-likelihoods (logarithmic values of probabilities of generating hypnograms given each Markov model) between each pair of models are shown in Table 6.2. Semi-Markov chain models with Weibull state durations perform significantly better than other models in terms of generative log-likelihoods on instances of hypnograms. Markov chain model and hidden Markov model imply expo- nential distribution of stage bout durations while semi-Markov not. With the increase of
6.1 HUMAN SLEEP PATTERNS
the number of stages from three to five in data, semi-Markov chain version further shows its superiority due to significantly better (p < 0.05) than others.
Table 6.2: T-tests of generative log-likelihoods (LL) of hypnograms on dynamical models. CI is confidence interval for the log likelihood difference in each case.
WNR H value P value CI LL(MM) - LL(SMM) 1 0.0086 [-18.5311, -2.7123] LL(SMM) - LL(HMM) 1 0.0061 [3.1023, 18.5397] WDL H value P value CI LL(MM) - LL(SMM) 1 0.0069 [-20.6407, -3.2936] LL(SMM) - LL(HMM) 1 0.0217 [1.4640, 18.4472] W5 H value P value CI LL(MM) - LL(SMM) 1 2.8972e-11 [-53.9527, -29.7896] LL(SMM) - LL(HMM) 1 3.3696e-13 [33.4582, 57.2735]
Initialization Evaluation: For deviation-based DTW clustering, Figure 6.5 shows the CDMC clusters (circles and triangles) coordinated by the parameters values of Weibull distribution (scale and shape) on wake stage in WNR dataset. The cluster assignments made by global weighted DTW clusters are better to separate patients in human sleep dataset into two clusters, in contrast with cluster boundaries made by standard DTW as the similarity metric.
During the below experimental procedure, model fit was significantly better for both global weighted DTW (gwDTW) clustering and stepwise deviated DTW (sdDTW) clus- tering as compared with standard DTW-driven clustering, as shown in Table 6.3. This shows that deviation-based DTW is superior to standard DTW as a similarity metric for initialization of CDMC clustering over human sleep data, as well as for standalone clus- tering over synthetic data as shown in section 2.4.
Experimental procedure, sleep data clustering: begin
Figure 6.5: Visualization of clusters over human sleep dataset using gwDTW as similarity measure. Coordinates are Weibull shape and scale parameters for Wake stage. Red circles and blue triangles denote gwDTW clusters; background colors represent DTW clusters.
m1, m2, m3 = DTW , gwDTW , sdDTW
for j := 1 to 3
for k := 1 to 3
(M, nlogll(j, k, l, . . . 244)) = CDMC(Dj, mk);
end
Perform Wilcoxon rank sum test on nlogll( j, 1 . . . 3, 1 . . . 244)
end
end