Class DetectRequest
- java.lang.Object
-
- com.azure.ai.anomalydetector.models.DetectRequest
-
public final class DetectRequest extends Object
The request of entire or last anomaly detection.
-
-
Constructor Summary
Constructors Constructor Description DetectRequest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Integer
getCustomInterval()
Get the customInterval property: Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {"granularity":"minutely", "customInterval":5}.TimeGranularity
getGranularity()
Get the granularity property: Optional argument, can be one of yearly, monthly, weekly, daily, hourly, minutely, secondly, microsecond or none.Float
getImputeFixedValue()
Get the imputeFixedValue property: Used to specify the value to fill, it's used when granularity is not "none" and imputeMode is "fixed".ImputeMode
getImputeMode()
Get the imputeMode property: Used to specify how to deal with missing values in the input series, it's used when granularity is not "none".Float
getMaxAnomalyRatio()
Get the maxAnomalyRatio property: Optional argument, advanced model parameter, max anomaly ratio in a time series.Integer
getPeriod()
Get the period property: Optional argument, periodic value of a time series.Integer
getSensitivity()
Get the sensitivity property: Optional argument, advanced model parameter, between 0-99, the lower the value is, the larger the margin value will be which means less anomalies will be accepted.List<TimeSeriesPoint>
getSeries()
Get the series property: Time series data points.DetectRequest
setCustomInterval(Integer customInterval)
Set the customInterval property: Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {"granularity":"minutely", "customInterval":5}.DetectRequest
setGranularity(TimeGranularity granularity)
Set the granularity property: Optional argument, can be one of yearly, monthly, weekly, daily, hourly, minutely, secondly, microsecond or none.DetectRequest
setImputeFixedValue(Float imputeFixedValue)
Set the imputeFixedValue property: Used to specify the value to fill, it's used when granularity is not "none" and imputeMode is "fixed".DetectRequest
setImputeMode(ImputeMode imputeMode)
Set the imputeMode property: Used to specify how to deal with missing values in the input series, it's used when granularity is not "none".DetectRequest
setMaxAnomalyRatio(Float maxAnomalyRatio)
Set the maxAnomalyRatio property: Optional argument, advanced model parameter, max anomaly ratio in a time series.DetectRequest
setPeriod(Integer period)
Set the period property: Optional argument, periodic value of a time series.DetectRequest
setSensitivity(Integer sensitivity)
Set the sensitivity property: Optional argument, advanced model parameter, between 0-99, the lower the value is, the larger the margin value will be which means less anomalies will be accepted.DetectRequest
setSeries(List<TimeSeriesPoint> series)
Set the series property: Time series data points.
-
-
-
Method Detail
-
getSeries
public List<TimeSeriesPoint> getSeries()
Get the series property: Time series data points. Points should be sorted by timestamp in ascending order to match the anomaly detection result. If the data is not sorted correctly or there is duplicated timestamp, the API will not work. In such case, an error message will be returned.- Returns:
- the series value.
-
setSeries
public DetectRequest setSeries(List<TimeSeriesPoint> series)
Set the series property: Time series data points. Points should be sorted by timestamp in ascending order to match the anomaly detection result. If the data is not sorted correctly or there is duplicated timestamp, the API will not work. In such case, an error message will be returned.- Parameters:
series
- the series value to set.- Returns:
- the DetectRequest object itself.
-
getGranularity
public TimeGranularity getGranularity()
Get the granularity property: Optional argument, can be one of yearly, monthly, weekly, daily, hourly, minutely, secondly, microsecond or none. If granularity is not present, it will be none by default. If granularity is none, the timestamp property in time series point can be absent.- Returns:
- the granularity value.
-
setGranularity
public DetectRequest setGranularity(TimeGranularity granularity)
Set the granularity property: Optional argument, can be one of yearly, monthly, weekly, daily, hourly, minutely, secondly, microsecond or none. If granularity is not present, it will be none by default. If granularity is none, the timestamp property in time series point can be absent.- Parameters:
granularity
- the granularity value to set.- Returns:
- the DetectRequest object itself.
-
getCustomInterval
public Integer getCustomInterval()
Get the customInterval property: Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {"granularity":"minutely", "customInterval":5}.- Returns:
- the customInterval value.
-
setCustomInterval
public DetectRequest setCustomInterval(Integer customInterval)
Set the customInterval property: Custom Interval is used to set non-standard time interval, for example, if the series is 5 minutes, request can be set as {"granularity":"minutely", "customInterval":5}.- Parameters:
customInterval
- the customInterval value to set.- Returns:
- the DetectRequest object itself.
-
getPeriod
public Integer getPeriod()
Get the period property: Optional argument, periodic value of a time series. If the value is null or does not present, the API will determine the period automatically.- Returns:
- the period value.
-
setPeriod
public DetectRequest setPeriod(Integer period)
Set the period property: Optional argument, periodic value of a time series. If the value is null or does not present, the API will determine the period automatically.- Parameters:
period
- the period value to set.- Returns:
- the DetectRequest object itself.
-
getMaxAnomalyRatio
public Float getMaxAnomalyRatio()
Get the maxAnomalyRatio property: Optional argument, advanced model parameter, max anomaly ratio in a time series.- Returns:
- the maxAnomalyRatio value.
-
setMaxAnomalyRatio
public DetectRequest setMaxAnomalyRatio(Float maxAnomalyRatio)
Set the maxAnomalyRatio property: Optional argument, advanced model parameter, max anomaly ratio in a time series.- Parameters:
maxAnomalyRatio
- the maxAnomalyRatio value to set.- Returns:
- the DetectRequest object itself.
-
getSensitivity
public Integer getSensitivity()
Get the sensitivity property: Optional argument, advanced model parameter, between 0-99, the lower the value is, the larger the margin value will be which means less anomalies will be accepted.- Returns:
- the sensitivity value.
-
setSensitivity
public DetectRequest setSensitivity(Integer sensitivity)
Set the sensitivity property: Optional argument, advanced model parameter, between 0-99, the lower the value is, the larger the margin value will be which means less anomalies will be accepted.- Parameters:
sensitivity
- the sensitivity value to set.- Returns:
- the DetectRequest object itself.
-
getImputeMode
public ImputeMode getImputeMode()
Get the imputeMode property: Used to specify how to deal with missing values in the input series, it's used when granularity is not "none".- Returns:
- the imputeMode value.
-
setImputeMode
public DetectRequest setImputeMode(ImputeMode imputeMode)
Set the imputeMode property: Used to specify how to deal with missing values in the input series, it's used when granularity is not "none".- Parameters:
imputeMode
- the imputeMode value to set.- Returns:
- the DetectRequest object itself.
-
getImputeFixedValue
public Float getImputeFixedValue()
Get the imputeFixedValue property: Used to specify the value to fill, it's used when granularity is not "none" and imputeMode is "fixed".- Returns:
- the imputeFixedValue value.
-
setImputeFixedValue
public DetectRequest setImputeFixedValue(Float imputeFixedValue)
Set the imputeFixedValue property: Used to specify the value to fill, it's used when granularity is not "none" and imputeMode is "fixed".- Parameters:
imputeFixedValue
- the imputeFixedValue value to set.- Returns:
- the DetectRequest object itself.
-
-