Skip to main content

Table 8 KNN classification algorithm hyperparameters and hyperparameter ranges used in grid-search tuning

From: Predicting chemotherapy response using a variational autoencoder approach

Hyperparameter name Hyperparameter description Hyperparameter range
n_neighbors Number of neighbors to use (1, 2, 3, \(\ldots\), 20)
weights Weight function used in prediction (‘uniform’, ‘distance’)
algorithm Algorithm used to compute the nearest neighbors (‘ball_tree’, ‘kd_tree’, ‘brute’, ‘auto’)
leaf_size Leaf sized passed to BallTree or KDTree (1, 2, 3, \(\ldots\), 20)
p Power parameter for the Minkowski metric (1, 2, 3, 4)