Machine learning models achieved an average AUC of 85%, 81%, 80%, and 82% across four models for predicting PCOS based on EHR data. Significant positive predictors included hormone levels (FSH, LH, estradiol, SHBG) and obesity, while negative predictors were gravidity and positive bHCG. The model has potential for early detection and integration into EHR systems for timely PCOS diagnosis and intervention. This evidence concerns the gene SHBG and Obesity.