Infants with neonatal opioid withdrawal syndrome commonly receive morphine treatment to manage their withdrawal signs. However, the effectiveness of this pharmacotherapy in managing the infants' withdrawal signs vary widely. We sought to understand how information available early in infant monitoring can anticipate this treatment response, focusing on early modified Finnegan Neonatal Abstinence Scoring System (FNASS) scores, polygenic risk for opioid dependence (polygenic risk score (PRS)), and drug exposure. Using k‐means clustering, we divided the 213 infants in our cohort into 3 groups based on their FNASS scores in the 12 hours before and after the initiation of pharmacotherapy. We found that these groups were pairwise significantly different for risk factors, including methadone exposure, and for in‐hospital outcomes, including total morphine received, length of stay, and highest FNASS score. Whereas PRS was not predictive of receipt of treatment, PRS was pairwise significantly different between a subset of the groups. Using tree‐based machine learning methods, we then constructed network graphs of the relationships among these groups, FNASS scores, PRS, drug exposures, and in‐hospital outcomes. The resulting networks also showed meaningful connection between early FNASS scores and PRS, as well as between both of those and later in‐hospital outcomes. These analyses present clinicians with the opportunity to better anticipate infant withdrawal progression and prepare accordingly, whether with expedited morphine treatment or non‐pharmacotherapeutic alternative treatments.