A computational model of the physiological mechanisms driving an individual's health towards onset of type 2 diabetes (T2D) is described, calibrated and validated using data from the Diabetes Prevention Program (DPP). The objective of this model is to quantify the factors that can be used for prevention of T2D. The model is energy and mass balanced and continuously simulates trajectories of variables including body weight components, fasting plasma glucose, insulin, and glycosylated hemoglobin among others on the time-scale of years. Modeled mechanisms include dynamic representations of intracellular insulin resistance, pancreatic beta-cell insulin production, oxidation of macronutrients, ketogenesis, effects of inflammation and reactive oxygen species, and conversion between stored and activated metabolic species, with body-weight connected to mass and energy balance. The model was calibrated to 331 placebo and 315 lifestyle-intervention DPP subjects, and one year forecasts of all individuals were generated. Predicted population mean errors were less than or of the same magnitude as clinical measurement error; mean forecast errors for weight and HbA1c were ~5%, supporting predictive capabilities of the model. Validation of lifestyle-intervention prediction is demonstrated by synthetically imposing diet and physical activity changes on DPP placebo subjects. Using subject level parameters, comparisons were made between exogenous and endogenous characteristics of subjects who progressed toward T2D (HbA1c > 6.5) over the course of the DPP study to those who did not. The comparison revealed significant differences in diets and pancreatic sensitivity to hyperglycemia but not in propensity to develop insulin resistance. A computational experiment was performed to explore relative contributions of exogenous versus endogenous factors between these groups. Translational uses to applications in public health and personalized healthcare are discussed.