# Hard and Soft EM in Bayesian Network Learning from Incomplete Data
## 4 Results  
The results, comprising 5520 incomplete data sets and the resulting BNs, are summarised in Figure 1 for the simulations in which we are using the network structure of the reference BNs. The decision tree shown in the Figure is intended to provide guidance to practitioners on which imputation algorithm appears to provide the best performance depending on the characteristics of their incomplete data problem. Each leaf in the decision tree corresponds to a subset of the scenarios we examined, grouped by the values of the experimental factors, and to a recommendation which EM algorithm has the best average KLD values. (Recommendations are also shown in Table 2 for  
EM algorithms markedly degrades as the sample size increases. However, the performance of hard EM remains constant as the sample size increases. Leaf G covers large BNs where the pattern of missingness is not fair (the missingness pattern is one of \"root\", \"leaf\", \"target\", \"high degree\")), and the random variables have balanced missingness distributions. In these cases, soft EM is the recommended algorithm (Figure 5). The performance of all EM algorithms shows only marginal improvements as the sample size increases, but low variance. As for the remaining leaves, we recommend the hard EM algorithm for leafs **D** and **F**. Leaf **D** covers small and medium BNs with balanced missingness distributions and medium or high missingness severity; leaf **F** covers only large BNs and unbalanced missingness. Finally, leaf **C** recommends soft and soft-forced EM for small and medium BNs with balanced missingness distributions, low missingness severity and a pattern of missingness that is not fair. As for the simulations that are based on the perturbed networks, the increased heterogeneity of the results makes it difficult to give recommendations as detailed as those above. We note, however, some overall trends:  
* Hard EM has the lowest \(\Delta\) KLD in 44/67 scenarios, compared to 16/67 (soft EM) and 7/67 (soft-forced EM). Soft EM has the highest \(\Delta\) KLD in 30/67 triplets, compared to 24/67 (soft-forced) and 13/67 (hard EM). Hence, hard EM can often outperform soft EM in the quality of estimated \(\widehat{\Theta}_{i}\), and it appears to be the worst-performing only in a minority of simulations. The opposite seems to be true for soft EM, possibly because it converges very slowly or it fails to converge completely in some simulations. The performance of soft-forced EM appears to be not as good as that of hard EM, but not as often the worst as that of soft EM. * We observe some negative \(\Delta\) KLD values for all EM algorithms: 7/67 (hard EM), 8/67 (soft EM), 5/67 (soft-forced). They highlight how all EM algorithms can sometimes fail to converge and produce good parameter estimates for the network structure of the reference BN, but not for the perturbed network structures. * Hard EM has the lowest \(\Delta\) KLD 13/30 times in small networks, 9/14 in medium networks and 21/23 in large networks in a monotonically increasing trend. At the same time, hard EM has the highest \(\Delta\) KLD in 8/30 times in small networks, 4/14 in medium networks and 0/23 in large networks, in a monotonically decreasing trend. This suggests that the performance of hard EM improves as the BNs increase in size: it provides the best \(\widehat{\Theta}_{i}\) more and more frequently, and it is never the worst performer in large networks. * Soft EM has the lowest \(\Delta\) KLD in 12/30 times in small networks, 5/14 in medium networks and 0/23 in large networks in a monotonically increasing trend. At the same time, soft EM has the highest \(\Delta\) KLD in 7/30 times in small networks, 6/14 in medium networks and 17/23 in large networks, in a monotonically increasing trend. Hence, we observe that soft EM is increasingly unlikely to be the worst performer as the size of the BN increases, but it is also increasingly likely outperformed by hard EM. * Soft-forced EM never has the lowest \(\Delta\) KLD in medium and large networks.