Optimizing K-Nearest Neighbors with Particle Swarm Optimization for Improved Classification Accuracy

This study aims to improve the performance of the K-Nearest Neighbors (KNN) algorithm in classifying public reviews of Batik Madura through optimizing the K value using the Particle Swarm Optimization (PSO) algorithm. Public reviews collected from the Google Maps platform are used as a dataset, with positive, negative, and neutral sentiment categories. Optimization of the K value is carried out to overcome the constraints of KNN performance, which is highly dependent on the K parameter, with PSO providing a more efficient approach than the grid search method. However, PSO also presents challenges such as sensitivity to parameter tuning and potential computational overhead. This study has succeeded in developing a web-based system using the Python Streamlit framework, which makes it easy for users to access sentiment analysis results. Testing shows that optimizing the K value with PSO increases the accuracy of KNN to 88.5% with an optimal K value of 19. However, this accuracy is not compared to other optimization techniques, leaving its relative advantage unverified. The results are expected to help Batik Madura entrepreneurs in evaluating public perception and guiding strategic innovations. Research outputs include a prototype, intellectual property registration, and journal publication, although the role of deep learning models is only briefly noted without further development.

Publication Details

Journal
Optimum: Journal of Economics and Development (University of Ahmad Dahlan Yogyakarta)
Published
2025-05-04
DOI
https://doi.org/10.26555/jiteki.v11i2.30775
Primary Topic
Data Mining and Machine Learning Applications
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Optimizing K-Nearest Neighbors with Particle Swarm Optimization for Improved Classification Accuracy

Optimum: Journal of Economics and Development (University of Ahmad Dahlan Yogyakarta)
Data Mining and Machine Learning Applications
article

Optimizing K-Nearest Neighbors with Particle Swarm Optimization for Improved Classification Accuracy

article en

Abstract

This study aims to improve the performance of the K-Nearest Neighbors (KNN) algorithm in classifying public reviews of Batik Madura through optimizing the K value using the Particle Swarm Optimization (PSO) algorithm. Public reviews collected from the Google Maps platform are used as a dataset, with positive, negative, and neutral sentiment categories. Optimization of the K value is carried out to overcome the constraints of KNN performance, which is highly dependent on the K parameter, with PSO providing a more efficient approach than the grid search method. However, PSO also presents challenges such as sensitivity to parameter tuning and potential computational overhead. This study has succeeded in developing a web-based system using the Python Streamlit framework, which makes it easy for users to access sentiment analysis results. Testing shows that optimizing the K value with PSO increases the accuracy of KNN to 88.5% with an optimal K value of 19. However, this accuracy is not compared to other optimization techniques, leaving its relative advantage unverified. The results are expected to help Batik Madura entrepreneurs in evaluating public perception and guiding strategic innovations. Research outputs include a prototype, intellectual property registration, and journal publication, although the role of deep learning models is only briefly noted without further development.

Optimum: Journal of Economics and Development (University of Ahmad Dahlan Yogyakarta)
Decent work and economic growth
Openalex Percentile: Top 38%
Data Mining and Machine Learning Applications
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Optimizing K-Nearest Neighbors with Particle Swarm Optimization for Improved Classification Accuracy · Optimum: Journal of Economics and Development (University of Ahmad Dahlan Yogyakarta) (2025) | TGRS Research Map | TGRS