Anais Dotis-Georgiou
Machine Learning and
Time Series Data
Welcome
Agenda
● Intro to Machine Learning
● K-Means
○ What is K-Means Clustering?
○ How is it used for time series data?
○ Code showing how K-Means is used
● https://github.com/Anaisdg/K-Mean
s_Influx
● https://github.com/mrahtz/sanger-m
achine-learning-workshop/blob/mas
ter/Unsupervised%20Learning.ipyn
b
K-Means: How does it apply to time series data?
● Step back
● Why should we use machine learning for time series data at all?
Moving Average
Stdev
Quartile Range
K-Means: What is K-Means Clustering
● 4 major categories: unsupervised, semi-supervised, supervised, and
reinforcement learning
● K-Means is an unsupervised learning technique
● Supervised vs Unsupervised
● K-Nearest Neighbor
● Euclidean:
● Centroid’s position:
●
Some code showing how I used K-Means
● Time series data is clusterable?
● Steps anomaly detection:
○ Segmentation & Windowing
○ Clustering
○ Reconstruction
○ Alerting
Segmentation
Take your data that looks like this...
Turn it into this...
Clustering
● Segment size
determines
polynomial
shape
● Cluster number
can determine
how much
coefficients
matter
Resources
K-Means Links
● https://github.com/Anaisdg/K-Means_Influx
● https://www.influxdata.com/blog/why-use-k-means-for-time-series-data-part-o
ne/
● https://medium.com/@dganais/why-use-k-means-for-time-series-data-part-tw
o-690e771c0b36
● https://github.com/mrahtz/sanger-machine-learning-workshop
Holt-Winters Links
● https://grisha.org/blog/2016/01/29/triple-exponential-smoothing-forecasting/
● https://docs.influxdata.com/influxdb/v1.6/query_language/functions/#holt-wint
ers
●
LoudML Links
● https://www.influxdata.com/blog/applying-machine-learning-models-to-influxd
b-with-loud-ml-docker-for-time-series-predictions/
● https://loudml.io/
Thank You
Machine learning and time series data

Machine learning and time series data