Anomaly Detection with tsoutliers
library(tsoutliers)
july7cat4 <- read.csv("C:/Users/Rinor/Downloads/sgt/july7cat4.csv")
attach(july7cat4)
task <- Average.percentageTracked
timeSeries <- ts(task, frequency=1, start=c(0,1))
outliers <- tso(timeSeries)
plot(outliers)

Anomaly Detection with AnomalyDetection
library(AnomalyDetection)
july7cat4 <- read.csv("C:/Users/Rinor/Downloads/sgt/july7cat4.csv")
attach(july7cat4)
task <- Average.percentageTracked
ano <- AnomalyDetectionVec(task, max_anoms=0.2, direction='both',period=2, plot=T)
plot(ano$plot)
