Publication: Social media mining with R
Abstract
Bu çalışmada, sosyal media web uygulamalarından veri çıkartma, veri hazırlama veya düzeltme, tokenizasyon, kelime sıklığı tahminleme, kelime yığınının duygu analizi ve görselleştirilmesi gibi birçok sosyal media madencilik tekniği R ortamında uygulanmıştır. Bu teknikler için R fonksiyonları oluşturularak, bu fonksiyonlar Türk Hava Yolları vaka çalışmasında uygulanmıştır. Sosyal media web uygulamalarından R programlama dili kullanılarak, söz konusu şirkete ait Facebook ve TripAdvisor web sayfasında yer alan yorum ve görüşleri kapsayan sosyal media verisi alınmıştır. Facebook ve TripAdvisor'dan veri temini için R paketleri kullanılmıştır. Bir sonraki aşamada, kompleks veri yapısı ve gereksiz sütunlar içeren dağınık ham veri, biri Facebook diğeri TripAdvisor için, dataframe yapısında iki farklı düzenli veri setine dönüştürülmüştür. Çalışmanın devamında yorum ve görüşlerden oluşan veri seti tokenize tekniği ile cümlelere ve ardından sözcüklere indirgenmiştir. Bunu yanısıra, veri seti içinde yer alan geçmiş zaman ve şimdiki zaman fiileri de kök fiil haline dönüştürülmüştür. Çalışmanın son aşamasında, tokenize edilmiş olan Facebook yorumları ve TripAdvisor görüşleri üzerinde; kelime sıklık sayımı, duygu analizi ve kelime yığını görselleştirmesi gibi çeşitli metin analiz teknikleri uygulanmıştır.
In this research study, many social media mining techniques, such as data extraction, data wrangling or tidying, tokenization, estimation of word frequency, sentiment analysis and visualization of word cloud, have been applied in R environment. The study builds R functions for these techniques. Later, these functions are used in the case study on Turkish Airlines. TurkishAirlines' social media data, i.e. comments posted by TurkishAirlines' Facebook followers and reviews posted by the customers on TripAdvisor Website, are scraped from the social media web applications using R programming language. R packages, built for web scraping, are used to retrieve data from Facebook and TripAdvisor. Afterward, the messy extracted data, with the complex data structure and unnecessary columns, are converted into two different tidy datasets, one for Facebook and other for TripAdvisor. Subsequently, the responses, either comments or reviews, are tokenized into sentence and words. The tokenized data have been cleaned by extracting NA values and stop words. Moreover, the verbs in different forms, such as present simple, present participle, past simple and past participle, are converted into the base form of verbs. Lastly, text analysis techniques such as word frequency count, sentiment analysis, and word cloud visualization are applied to tokenized Facebook comments and TripAdvisor reviews.
In this research study, many social media mining techniques, such as data extraction, data wrangling or tidying, tokenization, estimation of word frequency, sentiment analysis and visualization of word cloud, have been applied in R environment. The study builds R functions for these techniques. Later, these functions are used in the case study on Turkish Airlines. TurkishAirlines' social media data, i.e. comments posted by TurkishAirlines' Facebook followers and reviews posted by the customers on TripAdvisor Website, are scraped from the social media web applications using R programming language. R packages, built for web scraping, are used to retrieve data from Facebook and TripAdvisor. Afterward, the messy extracted data, with the complex data structure and unnecessary columns, are converted into two different tidy datasets, one for Facebook and other for TripAdvisor. Subsequently, the responses, either comments or reviews, are tokenized into sentence and words. The tokenized data have been cleaned by extracting NA values and stop words. Moreover, the verbs in different forms, such as present simple, present participle, past simple and past participle, are converted into the base form of verbs. Lastly, text analysis techniques such as word frequency count, sentiment analysis, and word cloud visualization are applied to tokenized Facebook comments and TripAdvisor reviews.
