Medical education can take advantage of big data to enhance the learning experience of students. This paper describes the development of TrainCoMorb, an online, data-driven application for medical students who can practice recognizing comorbidities and their attributable risk for negative outcomes. Trainees access TrainCoMorb to create scenarios of comorbidities, step-by-step, and see snapshots of the risk for inpatient death, hospital septicemia and the projected length of stay. The study utilized an enormous claims dataset (N=11m.). A dynamic Bayesian algorithm was developed, which calculates and updates conditional probabilities for the outcomes under study in each phase of an ongoing scenario. The trainee initiates a scenario by selecting demographics and a principal diagnosis, then adds chronic and hospital-acquired conditions to see a summary of the attributable risk in each phase. TrainCoMorb is anticipated to assist medical students gain a better understanding of comorbidities and their impact on clinical outcomes.