I want to calculate the k-nearest neighbors distance and the local outlier factor, which are used to construct continuous anomaly scores for each data point.
I use th