Call for Paper - November 2023 Edition
IJCA solicits original research papers for the November 2023 Edition. Last date of manuscript submission is October 20, 2023. Read More

Implementation of K-Modes Clustering in Determining Traffic Accident Patterns

International Journal of Computer Applications
Foundation of Computer Science (FCS), NY, USA
Year of Publication: 2021
Septyan Eka Prastya, Muhammad Zulfadhilah, Nurhaeni

Septyan Eka Prastya, Muhammad Zulfadhilah and Nurhaeni. Implementation of K-Modes Clustering in Determining Traffic Accident Patterns. International Journal of Computer Applications 183(30):32-37, October 2021. BibTeX

	author = {Septyan Eka Prastya and Muhammad Zulfadhilah and Nurhaeni},
	title = {Implementation of K-Modes Clustering in Determining Traffic Accident Patterns},
	journal = {International Journal of Computer Applications},
	issue_date = {October 2021},
	volume = {183},
	number = {30},
	month = {Oct},
	year = {2021},
	issn = {0975-8887},
	pages = {32-37},
	numpages = {6},
	url = {},
	doi = {10.5120/ijca2021921689},
	publisher = {Foundation of Computer Science (FCS), NY, USA},
	address = {New York, USA}


The increasing number of traffic accidents in South Kalimantan continues to occur, which needs to be considered by all parties, especially the traffic police. One of the efforts to reduce it is by finding the pattern of traffic accidents through the clustering method. Data from police reports will determine the grouping of traffic accidents based on day, time, victim, type of accident, geometry, age of the perpetrator, age of the victim, weather, Profession of the perpetrator, Profession of the victim, and type of vehicle involved which are some of the factors causing traffic accidents. This study aims to find the pattern of traffic accidents that often occur using the k-modes algorithm and to find the optimal k value; this study uses the Cohesion and Separation algorithm. The application of clustering using the k-modes algorithm will produce a traffic accident pattern based on the optimal k. The results of this study by testing the K-Modes algorithm at K=2, K=3, K=4, K=5, K=6, K=7, K=8, K=9, and K=10 with each experiment. -each k 5 times produces the optimal k value, which is located at K=3 in the 1st Cohesion experiment with a value of 2641. The pattern generated from the K-Modes algorithm has 3 patterns obtained from each cluster for K=3. At the final stage of determining the pattern of traffic accidents, it is known that the first cluster is the cluster with the largest size (61), namely when the weather is sunny, there are double accidents on the road with straight geometric shapes involving motorbikes and motorbikes.


  1. B. P. S. Indonesia, “Statistik Transportasi Darat 2015,” 2015.
  2. D. T. Nugrahadi and F. I. S. Rahayu, “Clustering Penentuan Potensi Kejahatan Daerah Di Kota Banjarbaru Dengan Metode K-Means,” Kumpul. J. Ilmu Komput., vol. 1, no. 1, pp. 33–45, 2014.
  3. A. RI, “Undang-Undang Republik Indonesia Nomor 22 Tahun 2009 Tentang Lalu Lintas dan Angkutan Umum,” 2009.
  4. P. C.E, “Analisis Karakteristik Kecelakaan dan Faktor Penyebab Kecelakaan Pada Lokasi Blackspot di Kota Kayu Agung,” Tek. Sipil dan Lingkung., vol. 2, no. 1, pp. 154–161, 2014.
  5. Fadlina, “Data Mining Untuk Analisa Tingkat Kejahatan Jalanan,” Inf. dan Teknol. Ilm., vol. 3, no. 1, pp. 144–154, 2014.
  6. Hexagraha A., “Data Mining Kredit Usaha Mikro di Bank XXXX,” in Konferensi Nasional Sistem Informasi 2014, STMIK Dipanegara Makassar, 2014, vol. 1, pp. 1–5.
  7. D. T. Larose and C. D. Larose, Discovering Knowledge in Data: An Introduction to Data Mining: Second Edition. 2014.
  8. P. . Simbolon, “Implementasi Data Mining Pada Sistem Persediaan Barang Menggunakan Algoritma Apriori ( Studi Kasus : Srikandi Cash Credit Elektronic dan Furniture ),” J. Ris. Komput., vol. 6, no. 4, pp. 401–406, 2019.
  9. A. . Prakash, “Review on K-Mode Clustering,” Int. J. Eng. Comput. Sci., vol. 5, no. 11, 2016.
  10. E. K. Nduru, E. Buulolo, and P. Pristiwanto, “IMPLEMENTASI ALGORITMA K-Modes UNTUK MENENTUKAN STRATEGI MARKETING STMIK BUDI DARMA,” KOMIK (Konferensi Nas. Teknol. Inf. dan Komputer), vol. 2, no. 1, pp. 12–19, 2018, doi: 10.30865/komik.v2i1.903.


Clustering, Cohesion and Separation, K-Modes, Traffic Accident, Patterns