title: How to evaluate my anomaly detection algorithm if I have no labelled data at all and Python code to get the anomolous data points for the same?
body: <p>I am trying to find anomalies in a data-set using Isolation forest algorithm from sklearn. However, I do not have any labelled (Anomaly/Non Anomaly) data at all. I understand that Isolation forest is an unsupervised algorithms and we get anomaly scores in return and after we get the anomaly scores, we can sort the anomaly scores and get top n socres based on a cut off. But how do we evaluate it if the model is predicting fine or not ? Also, how do we valiadte the same. Also, I am confused about how do I get scores back from Isolation forest. So, If possible, a python implementation of the same would be very helpful. I am doing this currently.</p>
  
  <pre><code>    clf = IsolationForest(n_estimators = 300, contamination = 0.10)
      clf.fit(df)
      scores_pred = clf.decision_function(df)
      print(len(scores_pred))
      print(len(df))
      df['scores'] = scores_pred
      print(df)`
  </code></pre>