Weighted k-nearest neighbors (weighted knn) is a variation of the k-nearest neighbors algorithm where the influence of each neighbor on the final prediction is weighted based on their distance from the query point. Instead of treating all neighbors equally, weighted knn assigns greater significance to closer neighbors, leading to potentially more accurate predictions and reducing the impact of outliers in the dataset.
congrats on reading the definition of weighted knn. now let's actually learn it.