Supervised Machine Learning: Optimization Framework and Applications with SAS and R