Analysis of IoT devices data using bayesian learning on fog computing