ANALISIS SENTIMEN PADA KOMENTAR PENGGUNA TIKTOK MENGENAI ISU LGBT+ DENGAN METODE TERM FREQUENCY-INVERSE DOCUMENT FREQUENCY DAN NAÏVE BAYES CLASSIFIER
- MUHAMMAD SABIT LANGGA
- 2025
ABSTRAK
Muhammad Sabit Langga (15210480), Analisis Sentimen Pada Komentar Pengguna TikTok Mengenai Isu LGBT+ Dengan Metode Term FrequencyInverse Document Frequency dan Naïve Bayes Classifier.
LGBT+ (Lesbian, Gay, Bisexual, Transgender, Intersex, Queer atau Questioning) merupakan kelompok individu yang memiliki identitas gender dan orientasi seksual yang berbeda dari mayoritas heteroseksual dan cisgender. Isu mengenai LGBT+ kerap menjadi topik kontroversial di berbagai negara, termasuk Indonesia. Media sosial TikTok dipilih sebagai objek penelitian karena memiliki jumlah aktif yang besar dan konten yang cenderung viral, terutama pada isu yang bersifat sensitif dan kontroversial. Peneliti mengumpulkan dataset sentimen komentar yang dikumpulkan melalui proses crawling dengan tools dari www.apify.com, khususnya melalui sistem TikTok Comments Scraper yang tersedia pada platform tersebut. Pada tanggal 27 Agustus 2025, total terdapat 4.915 komentar, namun karena batasan akses pihak ketiga, hanya 3.650 komentar yang berhasil diunduh dan dijadikan sampel analisis. Dataset yang telah dikumpulkan oleh peneliti kemudian diolah menggunakan Preprocessing, labelling, Term Frequecy-Inverse Document Frequency (TF-IDF) dan Algoritma Naïve Bayes untuk mengklasifikasikan komentar sentimen ke dalam kategori positive dan negative. Setelah dilakukan penghapusan sentimen yang kosong, jumlah data sebelumnya yakni terdapat 3.650 sentimen komentar menjadi 3.435 sentimen komentar. Karena fokus analisis hanya pada sentimen positive dan negative, data yang digunakan berkurang menjadi 1.369 komentar tanpa memasukkan kelas neutral. yang digunakan, 977 komentar termasuk dalam kelas bersentimen negative dan 392 komentar termasuk dalam kelas bersentimen positive. Berdasarkan data tersebut, diperoleh bahwa 28,6 % opini pengguna komentar TikTok mengenai isu LGBTQ+ bersentimen positive, sedangkan 71,4 % opini pengguna komentar tersebut bersentimen negative. Hasil dari penerapan Term Frequecy-Inverse Document Frequency (TF-IDF) dijadikan fitur representasi teks, dengan matriks berukuran (274,1.500) pada data latih dan (70, 1.500) pada data uji. Akurasi yang dihasilkan dari pengujian data ini. Hasil pengujian data terbukti dapat mengklasifikasikan algoritma Naïve Bayes Classifier (NBC) terhadap sentimen komentar TikTok terkait isu LGBT+ yaitu memiliki akurasi 78,47%, Presesi 98,98%, Recall 77,29% dan F1-score 86,84% melebihi tingkat akurasi 50% yang terdapat pada hipotesis H1 (model dapat melebihi 50%) dinyatakan diterima. Maka penelitian ini membuktikan bahwa Algoritma Naïve Bayes Classifier (NBC) dapat efektif dalam mengklasifikasikan sentimen komentar pada media sosial TikTok terkait isu LGBT+.
Kata Kunci: LGBT+, TikTok, Term Frequecy-Inverse Document Frequency, Algoritma Naïve Bayes Classifier.
ABSTRACT
Muhammad Sabit Langga (15210480), Sentiment Analysis of TikTok User Comments on LGBT+ Issues Using Term Frequency–Inverse Document Frequency and the Naïve Bayes Classifier.
LGBT+ (Lesbian, Gay, Bisexual, Transgender, Intersex, Queer or Questioning) refers to individuals whose gender identities and sexual orientations differ from the heterosexual and cisgender majority. The LGBT+ issue is often controversial in many countries, including Indonesia. TikTok was chosen as the research platform due to its large active user base and the tendency for sensitive or controversial content to go viral there. The researcher collected a dataset of user comments by crawling with tools from www.apify.com—specifically, the TikTok Comments Scraper available on that platform. As of August 27, 2025, a total of 4,915 comments had been identified, but due to third-party access limitations only 3,650 comments were successfully downloaded and used as the analysis sample. The collected dataset was then processed through the following steps: preprocessing, labeling, Term Frequency–Inverse Document Frequency (TF-IDF) feature extraction, and classification using the Naïve Bayes algorithm to categorize comment sentiment as either positive or negative. After removing comments with empty sentiment labels, the dataset size decreased from 3.650 to 3.435 comments. Because this study focused exclusively on positive and negative sentiments, neutral comments were excluded, leaving 1,369 comments in the final analysis: 977 negative and 392 positive. Based on these figures, 28.6 % of TikTok user opinions on LGBTQ+ issues were positive, while 71.4 % were negative. TF-IDF was applied to represent each comment as a feature vector, resulting in a feature matrix of size 274 × 1.500 for the training set and 70 × 1.500 for the test set. The Naïve Bayes classifier achieved an accuracy of 78.47 %, precision of 98.98 %, recall of 77.29 %, and an F1-score of 86.84 %, surpassing the 50 % accuracy threshold posited in hypothesis H1 (that the model would exceed 50 %). Therefore, this research demonstrates that the Naïve Bayes classifier is effective for sentiment classification of TikTok comments concerning LGBT+ issues.
Keywords: LGBT+, TikTok, Term Frequecy-Inverse Document Frequency, Naïve Bayes Classifier Algorithm
https://repository.bsi.ac.id/repo/72121/ANALISIS-SENTIMEN-PADA-KOMENTAR-PENGGUNA-TIKTOK--MENGENAI-ISU-LGBT--DENGAN-METODE-TERM-FREQUENCY-INVERSE-DOCUMENT-FREQUENCY-DAN-NAÏVE-BAYES-CLASSIFIER
Anda dapat membaca file tugas akhir ini di repository.
Detail Informasi
Tugas Akhir ini ditulis oleh :
- 15210480 - MUHAMMAD SABIT LANGGA
- Prodi : Informatika
- Kampus : Kramat 98
- Tahun : 2025
- Pembimbing : Ade Surya Budiman, ST, M.Kom
- Kode : 0093.S1.15.SKRIPSI.I.2025
- Status Akses : Open Access
- Diinput oleh : AXD
- Terakhir update : 22 Oktober 2025
- Dilihat : 113 kali