twitter / AnomalyDetection

Anomaly Detection with R
GNU General Public License v3.0
3.55k stars 776 forks source link

case when max_outliers = 0 #40

Open Mullefa opened 9 years ago

Mullefa commented 9 years ago

If the user is running AnomalyDetectionTs() we can assume that they are looking for outliers. Therefore, could a warning be thrown if the user sets a percentage (max_anoms) that results in max_outliers being 0?

On a similar note, I think this degenerate case demonstrates that it is safer to iterate over seq_len(max_outliers) rather than 1:max_outliers.