- Start terminal and
cd
into the directory - Compile all the java files
- run
java TaxiClusters
.
The values of MinPts and eps can also be changed.
The goal of this project is to implement the DBSCAN algorithm in order to cluster various trip records using the GPS coordinates of the starting points.
Link to an explanation of the DBSCAN algorithm: https://en.wikipedia.org/wiki/DBSCAN
The dataset I am using is a CSV file containing all the trip records for January 15, 2009 between 12pm and 1pm in New York City.
The implementation is object-oriented programming therefore it will contain different classes such as:
- TaxiClusters: the main application that processes the data, and the values of the parameters
MinPts
andeps
. It also creates a CSV file for each cluster created that contains all the points in it. A function that gives you the 10 biggest clusters is also implemented (It can be commented in on line 172 ofTaxiClusters.java
to get them too). - GPSCoord: a class with the attributes latitude and longitude.
- TripRecord: a class with attributes
label
,pickup_DateTime
,pickup_Location
,dropoff_Location
andtrip_Distance
. - Cluster: a class with attributes
clusterId
,points
,position
andnumPoints
.
These are the 10 biggest obtained are shown in the map below, each with its own colour.
Link to map: https://www.google.com/maps/d/edit?mid=1kfZBIcvRJEtT0D0xaKl4MxH1cece_yz8&usp=sharing