## Appendix B  
Given: Set S of examples \((x_{1},y_{1})\),...,\((x_{m},y_{m})\) with minority class  
Weak learner (decision tree), WeakLearn  
Number of iterations, T  
Desired percentage of total instances to be represented by the minority class, N  
```
1:Initialize \(D_{1}(i)=\frac{1}{m}\) for all i
2:for t do = 1,2,...,T
3: Create temporary training dataset \(S^{\prime}_{t}\) with distribution \(D^{\prime}_{t}\) using random undersampling
4: Call WeakLearn, providing it with examples \(S^{\prime}_{t}\) and their weights \(D^{\prime}_{t}\). 5: Get back a hypothesis \(h_{t}\): XxY \(\rightarrow\) [0,1]. 6: Calculate a pseudo-loss (for S and \(D_{t}\)):
7: \[\epsilon_{t}=\sum_{(i,y):y_{i}\
eq y}D_{t}(i)(1-h_{t}(x_{i},y_{i})+h_{t}(x_{i},y))\]
8: Calculate the weight update parameter:
9: \[\alpha_{t}=\frac{\epsilon_{t}}{1-\epsilon_{t}}\]
10: Update \(D_{t}\):
11: \[D_{t+1}(i)=D_{t}(i)\alpha_{t}^{\frac{1}{2}(1+h_{t}(x_{i},y_{i})-h_{t}(x_{i},y \
eq y_{i}))}\]
12: Normalize \(D_{t+1}\): Let \(Z_{t}=\sum_{i}D_{t+1}(i)\)
13: \[D_{t+1}(i)=\frac{D_{t+1}(i)}{Z_{t}}\]
14:endfor
15: Output the final hypothesis:

\[H(x)=\underset{y\in Y}{argmax}\sum_{t=1}^{T}h_{t}(x,y)log\frac{1}{\alpha_{t}}\]

## References

* [PERSON] (2014) [PERSON] A Comprehensive Review on Metabolic Syndrome. _Cardiol. Res. Pract._**2014**, 1-21. [CrossRef]
* [PERSON] et al. (2008) [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON] The Metabolic Syndrome. _Endocr. Rev._**2008**, _29_, 777-822. [CrossRef] [PubMed]
* [PERSON] and [PERSON] (2017) [PERSON]; [PERSON] Coronary Heart Disease. In _International Encyclopedia of Public Health_, 2 nd ed. ; Academic Press: Cambridge, MA, USA, 2017; Volume 2, pp. 159-167. [CrossRef] [PubMed]
* WHO (2013) WHO. _Global Action Plan for the Prevention and Control of Noncommunicable Diseases 2013-2020_; World Heal. Organ: Geneva, Switzerland, 2013; ISBN 978-9-24150-623-6. [CrossRef]
* [PERSON] and [PERSON] (2008) [PERSON]; [PERSON] [PERSON] Metabolic syndrome in the southeast of Barranquilla (Colombia). _Salud Uninore_**2008**, 24, 40-52. * [PERSON] et al. (2003) [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON] Seventh Report of the Joint National Committee on Prevention, Detection, Evaluation, and Treatment of High Blood Pressure. _Hypertension_**2003**, _42_, 1206-1252, doi:10.1161/01.HYP.0000107251.49515.c2
* [PERSON] et al. (2012) [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON] Metabolic Syndrome and Risk of Cancer: A systematic review and meta-analysis. _Diabetes Care_**2012**, _35_, 2402-2411. [CrossRef] [PubMed]
* [PERSON] et al. (2004) [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON]; [PERSON] The Metabolic Syndrome and Chronic Kidney Disease in U.S. Adults. _Ann. Intern. Med._**2004**, _140_, 167. [CrossRef] [PubMed]
* [PERSON] (2006) [PERSON] Metabolic Syndrome: Connecting and Reconciling Cardiovascular and Diabetes Worlds. _J. Am. Coll. Cardiol._**2006**, _47_, 1093-1100. [CrossRef] [PubMed]
* [PERSON] (2008) [PERSON] Metabolic Syndrome Pandemic. _Arterioscler. Thromb. Vasc. Biol._**2008**, _28_, 629-636. [CrossRef]
* [PERSON] et al. (2002) [PERSON]; [PERSON]; [PERSON] Prevalence of the Metabolic Syndrome Among US Adult. _J. Am. Med. Assoc._**2002**, _287_, 356-359. [CrossRef]
* [PERSON] (2011) [PERSON] [PERSON]; [PERSON] [PERSON] Persistent Increase of Prevalence of Metabolic Syndrome Among U.S. Adults: NHANES III to NHANES 1999-2006. _Diabetes Care_**2011**, _34_, 216-219. [CrossRef]
* [PERSON] et al. (2015) [PERSON]; [PERSON]; [PERSON]; [PERSON] Prevalence of the Metabolic Syndrome in the United States, 2003-2012. _JAMA_**2015**, _313_, 1973-1974. [CrossRef]
* [PERSON] (2002) [PERSON] The Metabolic Syndrome and Total and Cardiovascular Disease Mortality in Middle-aged Men. _JAMA_**2002**, _288_, 2709-2716. [CrossRef] [PubMed]
* [PERSON] (2007) [PERSON] Metabolic Syndrome: A Multiplex Cardiovascular Risk Factor. _J. Clin. Endocrinol. Metab._**2007**, _92_, 399-404. [CrossRef] [PubMed]
* [PERSON] (2010) [PERSON] Metabolic syndrome as a risk factor for diabetes.