A novel anomaly detection algorithm for sensor data under uncertainty