Anomaly Detection In Power BI

In this article, we will be talking about one of the interesting features of Power BI, which is Anomaly Detection. We will be talking about everything in detail with the help of an example.
  • In a simple word, Anomaly means “Oddity” in data.
  • Anomaly detection helps us to enhance our line charts by automatically detecting anomalies in our time series data.
  • It also provides explanations for the anomalies to help with root cause analysis.
  • With just a couple of clicks, we can easily find insights without having to slice and dice the data.
  • The anomaly detection algorithm is based on the concept of “Sensitivity”. We will be talking about this with an example.
Download Sample File: GITHUB
 

Real-life Example

 
I have time series Sales Profit data for one organization. I want to detect specific anomalies from my data. So, how can I achieve that? Let me show you.
 
Note
This feature is in preview at this moment. So, make sure you enable the preview feature first.
 
 
  • Create a line chart for time series data. I’m representing Profit by Order date.
 
  • To detect the anomalies from the data select visualization and click on the Analytics section.
 
  • Here, we have the Find anomalies section.
 
  • Click on Add.
 
  • Here, this will have the following properties.


    Sensitivity for Anomaly Detection.
     
    If you increase the sensitivity, the algorithm is more sensitive to changes in your data. In that case, even a slight deviation is marked as an anomaly.
     
    Let’s say I’m having a sensitivity of 70% in my data. So, the algorithm has detected more data points as an anomaly from the data.
     


    If you decrease the sensitivity, the algorithm is more selective on what it considers an anomaly. Let’s decrease the anomalies by 30%. Then we have fewer data points detected as an anomaly.
     

  • Let’s click on any anomaly data point.
 
This will give us the reason in a natural language to show the reason for the inconsistency in the data.
 
Also, this gives us “Possible explanations” with the affected field information for the anomaly. We can also include that explanation in the chart easily.
  • Now, let’s talk about the “Explain by” property. In #6 we check the “Possible explanations” based on the different fields from the report. Now, let’s say I want to define that. I need explanations, only based on region and segment. Then we need to set those two fields there.
So, as an end outcome, this will only provide explanations based on Region and Segment.
 
  • We can define Anomaly Shape, size, and color using the following properties.
  • Let’s say if we want to identify the range for the specified data point we can configure this property.
 
Example
 
Here, the gray line defines the MAX and MIN range for the specific data point. For any anomaly point, we can check what should be the expected range to avoid an anomaly.
 
 
Limitations
  • At this moment this feature is not available for Mobile devices.
References
  1. Anomaly Detection Documentation
  2. Reference for files and example

Conclusion

 
This is how we can configure Anomaly detection in Power BI. Isn’t that amazing?
 
Happy reporting!