Having performed the DBSCAN algorithm, I implemented OPTICS which extends DBSCAN algorithm.
Preprocessed the data by normalising/ standardising the data and converting the object values to numerical ones.
Used an Haversine distance formula to calculate the distance between each location.
Later applied the OPTICS algorithm:
optics = OPTICS(min_samples=5, metric=’precomputed’)
optics.fit(haversine_matrix)
Identified the noise points and extracted cluster information such as core samples and reachability distances.
Also visualised the clusters on the map to understand the spatial distribution.