Skip to content

Instantly share code, notes, and snippets.

@icebeam7
Last active December 18, 2019 23:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save icebeam7/fdfdfce1270d6295bf63f3f7bf3f0b0e to your computer and use it in GitHub Desktop.
Save icebeam7/fdfdfce1270d6295bf63f3f7bf3f0b0e to your computer and use it in GitHub Desktop.
AnomalyDetector: AnomalyAnalisis.cs
using System;
using System.Collections.Generic;
namespace AdExchangeAnalyzer.Models
{
public class DataPoint
{
public DateTime Timestamp { get; set; }
public float Value { get; set; }
}
public class DataRequest
{
public string Granularity { get; set; }
public List<DataPoint> Series { get; set; }
public double MaxAnomalyRatio { get; set; }
public int Sensitivity { get; set; }
}
public class DataResult
{
public float[] ExpectedValues { get; set; }
public bool[] IsAnomaly { get; set; }
public bool[] IsNegativeAnomaly { get; set; }
public bool[] IsPositiveAnomaly { get; set; }
public float[] LowerMargins { get; set; }
public int Period { get; set; }
public float[] UpperMargins { get; set; }
}
public class DataPointEx
{
public DateTime Timestamp { get; set; }
public float Value { get; set; }
public bool IsAnomaly { get; set; }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment