I'm new to R and I'm working on poc to find anomoly in data set. I need to add flag with Boolean value if it's outlier. Can anyone suggest me some good approach.i tried with anomoly detection and few other but no luck.
Looks like I'm doing it in wrong way.
Below sample code I tried plot data and getting time decompose function missing error.
anomalize(remainder, alpha = 0.2, max_anoms = 0.2)%>%
plot_anomalies(time_recompose = T)+
ggtitle("20% anomaly Allowed")
Need help to find good approach to do it.