Abstract:AIM: To predict best-corrected visual acuity (BCVA) by machine learning in patients with ocular trauma who were treated for at least 6mo. METHODS: The internal dataset consisted of 850 patients with 1589 eyes and an average age of 44.29y. The initial visual acuity was 0.99 logMAR. The test dataset consisted of 60 patients with 100 eyes collected while the model was optimized. Four different machine-learning algorithms (Extreme Gradient Boosting, support vector regression, Bayesian ridge, and random forest regressor) were used to predict BCVA, and four algorithms (Extreme Gradient Boosting, support vector machine, logistic regression, and random forest classifier) were used to classify BCVA in patients with ocular trauma after treatment for 6mo or longer. Clinical features were obtained from outpatient records, and ocular parameters were extracted from optical coherence tomography images and fundus photographs. These features were put into different machine-learning models, and the obtained predicted values were compared with the actual BCVA values. The best-performing model and the best variable selected were further evaluated in the test dataset. RESULTS: There was a significant correlation between the predicted and actual values [all Pearson correlation coefficient (PCC)>0.6]. Considering only the data from the traumatic group (group A) into account, the lowest mean absolute error (MAE) and root mean square error (RMSE) were 0.30 and 0.40 logMAR, respectively. In the traumatic and healthy groups (group B), the lowest MAE and RMSE were 0.20 and 0.33 logMAR, respectively. The sensitivity was always higher than the specificity in group A, in contrast to the results in group B. The classification accuracy and precision were above 0.80 in both groups. The MAE, RMSE, and PCC of the test dataset were 0.20, 0.29, and 0.96, respectively. The sensitivity, precision, specificity, and accuracy of the test dataset were 0.83, 0.92, 0.95, and 0.90, respectively. CONCLUSION: Predicting BCVA using machine-learning models in patients with treated ocular trauma is accurate and helpful in the identification of visual dysfunction.