Machine Learning Algorithms in Statistical Modelling Bridging Theory and Application