SlideShare a Scribd company logo
1 of 27
DETECTING CONTROVERSY
IN MICROPOSTS
An approach based on word similarity with an
application to the analysis of tweets
#Candidato #Relatore
@stefanodp0 @remo_pareschi
UNIVERSITÀ DEGLI STUDI DEL MOLISE
DIPARTIMENTO DI BIOSCIENZE E TERRITORIO
http://expandedramblings.com/index.php/march-2013-by-the-numbers-a-few-amazing-twitter-stats/
MILIONI
UTENTI ATTIVI AL
MESE
MILIONI
UTENTI ATTIVI AL
MESE
http://expandedramblings.com/index.php/march-2013-by-the-numbers-a-few-amazing-twitter-stats/
MILIARDI
TWEETS INVIATI
129 km
15 x
http://expandedramblings.com/index.php/march-2013-by-the-numbers-a-few-amazing-twitter-stats/
MILIONI
TWEETS AL
GIORNO
OPINIONI
FATTI
(OGGETTIVI)
(SOGGETTIVE)
1 Aziende
2 Governi
4
Compagnie di
marketing
3 Agenzie di sicurezza
Identificarle
Comprenderle
Raggrupparle
Necessità di Per…
ATOMICAN APPROACH TO DETECT
CONTROVERSY IN MICROPOSTS
Matrice delle somiglianze
𝑪 𝟏
[𝟎 ÷ 𝜶)
𝑪𝒊
[(𝒊 − 𝟏)𝜶 ÷ 𝒊𝜶)
𝑪 𝒏
[(𝒏 − 𝟏)𝜶 ÷ 𝒏𝜶)
Cluster Classi di similarità
tweet1 𝑡𝑤𝑒𝑒𝑡1 ∞
tweet2 𝑡𝑤𝑒𝑒𝑡2 ∞
… …
tweeti 𝑡𝑤𝑒𝑒𝑡𝑖 ∞
… …
𝑪 𝟏
[𝟎 ÷ 𝜶)
𝑪𝒊
[(𝒊 − 𝟏)𝜶 ÷ 𝒊𝜶)
𝑪 𝒏
[(𝒏 − 𝟏)𝜶 ÷ 𝒏𝜶)
Cluster Classi di similarità
tweet1 𝑡𝑤𝑒𝑒𝑡1 ∞
tweet2 𝑡𝑤𝑒𝑒𝑡2 ∞
… …
tweeti 𝑡𝑤𝑒𝑒𝑡𝑖 ∞
… …
10 3,4
-4,567 1
-1,234
𝒔𝒆𝒏𝒕𝒊𝒎𝒆𝒏𝒕 𝑺𝑪 =
𝒂𝒅𝒋∈𝑺𝑪
𝒔𝒆𝒏𝒕𝒊𝑾𝒐𝒓𝒅𝒔(𝒂𝒅𝒋) ∙ 𝒐𝒄𝒄𝒖𝒓𝒓𝒆𝒏𝒄𝒆𝒔(𝒂𝒅𝒋)
𝒄𝒐𝒏𝒕𝒓𝒐𝒗𝒆𝒓𝒔𝒚 𝑪 =
𝑺𝑪∈𝑪 𝒔𝒆𝒏𝒕𝒊𝒎𝒆𝒏𝒕(𝑺𝑪) ∙ |𝑺𝑪|
𝑺𝑪𝝐𝑪 |𝑺𝑪|
𝑺𝑪 = 𝑺𝒊𝒎𝒊𝒍𝒂𝒓𝒊𝒕𝒚 𝑪𝒍𝒂𝒔𝒔
𝑪 = 𝑪𝒍𝒖𝒔𝒕𝒆𝒓
Qual è il miglior
numero di cluster ?
Non vengono fatte
distinzioni nelle
osservazioni
CLUSTER RIDOTTI
Vengono fatte
troppe distinzioni nelle osservazioni
CLUSTER ELEVATI
Miglior bilanciamento tra
informazione e omogeneità
dei dati associati a ciascun cluster
𝜶
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊 𝒍𝒐𝒈 𝒇𝒊
ENTROPIA
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊 𝒍𝒐𝒈 𝒇𝒊
ENTROPIA
…
112 cluster
ENTROPIA PENALIZZATA
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊 𝒍𝒐𝒈 𝒇𝒊 − 𝒍𝒐𝒈(𝒌 𝛼)
0.755
ENTROPIA PENALIZZATA
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊 𝒍𝒐𝒈 𝒇𝒊 − 𝒍𝒐𝒈(𝒌 𝛼)
0.755
2 cluster
ENTROPIA PONDERATA
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊
𝟐
𝒍𝒐𝒈 𝒇𝒊
0.130
ENTROPIA PONDERATA
−
𝒊=𝟏
𝒌 𝜶
𝒇𝒊
𝟐
𝒍𝒐𝒈 𝒇𝒊
0.130
12 cluster
Risultati su 13000 tweets analizzati
L’entropia ponderata dà i migliori risultati
identificazione dei
FLAMER
DETECTING CONTROVERSY
IN MICROPOSTS
STEFANODALLAPALMA
15dicembre2016

More Related Content

More from Stefano Dalla Palma

Introduction to Mutation Testing
Introduction to Mutation TestingIntroduction to Mutation Testing
Introduction to Mutation TestingStefano Dalla Palma
 
Introduction to Machine Learning with examples in R
Introduction to Machine Learning with examples in RIntroduction to Machine Learning with examples in R
Introduction to Machine Learning with examples in RStefano Dalla Palma
 
Introduction to Machine Learning concepts
Introduction to Machine Learning conceptsIntroduction to Machine Learning concepts
Introduction to Machine Learning conceptsStefano Dalla Palma
 
Apache Mahout Architecture Overview
Apache Mahout Architecture OverviewApache Mahout Architecture Overview
Apache Mahout Architecture OverviewStefano Dalla Palma
 
An Empirical Study on Bounded Model Checking
An Empirical Study on Bounded Model CheckingAn Empirical Study on Bounded Model Checking
An Empirical Study on Bounded Model CheckingStefano Dalla Palma
 
UML, ER and Dimensional Modelling
UML, ER and Dimensional ModellingUML, ER and Dimensional Modelling
UML, ER and Dimensional ModellingStefano Dalla Palma
 
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...Stefano Dalla Palma
 

More from Stefano Dalla Palma (10)

Introduction to Mutation Testing
Introduction to Mutation TestingIntroduction to Mutation Testing
Introduction to Mutation Testing
 
Artificial Neural Networks
Artificial Neural NetworksArtificial Neural Networks
Artificial Neural Networks
 
Decision Tree learning
Decision Tree learningDecision Tree learning
Decision Tree learning
 
Introduction to Machine Learning with examples in R
Introduction to Machine Learning with examples in RIntroduction to Machine Learning with examples in R
Introduction to Machine Learning with examples in R
 
Introduction to Machine Learning concepts
Introduction to Machine Learning conceptsIntroduction to Machine Learning concepts
Introduction to Machine Learning concepts
 
Apache Mahout Architecture Overview
Apache Mahout Architecture OverviewApache Mahout Architecture Overview
Apache Mahout Architecture Overview
 
An Empirical Study on Bounded Model Checking
An Empirical Study on Bounded Model CheckingAn Empirical Study on Bounded Model Checking
An Empirical Study on Bounded Model Checking
 
UML, ER and Dimensional Modelling
UML, ER and Dimensional ModellingUML, ER and Dimensional Modelling
UML, ER and Dimensional Modelling
 
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...
VCCFinder: Finding Potential Vulnerabilities in Open-Source Projects to Assis...
 
Prolog in a nutshell
Prolog in a nutshellProlog in a nutshell
Prolog in a nutshell
 

Detecting controversy in microposts: an approach based on word similarity with an application to the analysis of tweets

Editor's Notes

  1. la piattaforma di microblogging è usata da numerosi utenti per esprimere le loro opinioni riguardo vari argomenti e risulta così essere una valida sorgente delle opinioni delle persone; il “pubblico” di Twitter…
  2. il “pubblico” di Twitter varia dal normale utente alla celebrità, alle organizzazioni e aziende più famose, fino al presidente di una nazione. Questi postano brevi messaggi riguardo un’ampia varietà di topics - a differenza di altri siti in cui si è legati ad argomenti specifici – e spesso il valore attribuito ai loro messaggi dipende dal ruolo che questi hanno all’interno della società
  3. Twitter contiene un enorme numero e varietà di dati. Da quanto è nato sono stati inviati piu di 300 miliardi di tweets.
  4. Si pensi che, se pensassimo di scrivere i tweets su dei fogli A4 e creare una pila di fogli, il numero di tweets inviati finora sarebbe tale da formare una pila alta 129 km: 155 volte lo skyline di Dubai, il palazzo più alto del mondo che misura circa 800m.
  5. È in continua espansione. È pertanto facile poter collezionare milioni di tweet e spaziare su diversi argomenti;
  6. Dato il numero crescente di questi messaggi, la rilevazione della controversia è molto importante, soprattutto per…
  7. Trovare il giusto numero di cluster è importante. Infatti, individuare un numero ridotto di cluster o troppo elevato può portare a risultati poco producenti, dovuti al fatto che nel primo caso, la differenza tra la quantità di informazione totale e quella contenuta nei cluster viene persa a causa del fatto che non vengono fatte distinzioni nelle osservazioni, mentre nel secondo ne vengono fatte troppe. Trovare alpha che permette di bilanciare la quantità di informazione e l’omogeneità dei dati associati a ciascun cluster. A tal proposito ci viene in aiuto l’entropia con la quale misuriamo il grado di informazione presente in ciascun cluster.
  8. Andremo a scegliere, tra un intervallo di possibili valori di alpha, quello che massimizza l’entropia.
  9. PARLARE DEI PROBLEMI DOVUTI ALL’ENTROPIA: scelta della soglia minore
  10. PARLARE DEI PROBLEMI DOVUTI ALL’ENTROPIA: scelta della soglia minore
  11. PARLARE DEI PROBLEMI DOVUTI ALL’ENTROPIA PENALIZZATA: scelta di alpha tale che numero di cluster sempre = 2
  12. Nonostante un elevata omogeneità dei dati, pago un prezzo troppo alto in termini di informazione persa, pertanto, a fronte di questi problemi ho introdotto una misura di entropia ponderata su….