finding correlations between geographical twitter sentiment and stock prices

24
Finding Correlations Between Geographical Twitter Sentiment and Stock Prices Undergraduate Researchers: Juweek Adolphe Ressi Miranda Graduate Student Mentor: Zhaoyu Li Faculty Advisor: Dr. Yi Shang

Upload: kordell

Post on 05-Jan-2016

35 views

Category:

Documents


1 download

DESCRIPTION

Finding Correlations Between Geographical Twitter Sentiment and Stock Prices. Undergraduate Researchers: Juweek Adolphe Ressi Miranda Graduate Student Mentor: Zhaoyu Li Faculty Advisor: Dr. Yi Shang. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Finding Correlations Between Geographical Twitter Sentiment

and Stock Prices

Undergraduate Researchers: Juweek Adolphe Ressi Miranda Graduate Student Mentor: Zhaoyu Li Faculty Advisor: Dr. Yi Shang

Page 2: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Research Project● Find out whether a specific

demographic’s Twitter sentiment has a more significant correlation to a company’s stock price than another

Page 3: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Correlate

Page 4: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Previous Work

Sources: Sentidex.com

Page 5: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Tools● Sentiment Analysis

o Lexicon based approach o finding the sentiment of individual words to

get total sentiment of sentence● Tweepy Streaming API

o Filtered by topic, language● Matplotlib

o Graphs

Page 6: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Methodology: Area● Sector: Food & Restaurants● Standard & Poor’s 500● Companies: McDonalds and Starbucks

o Key searches: Ticket Symbol, Keywords, Company

Products Key Words Sample:

● $MCD, Big Mac, McDonalds, Happy Meal● $SBUX, Starbucks, Caramel Macchiato

Page 7: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Making a Dataset● Other dataset didn’t work● Streamed Tweets for 5 days

o Filtered by keywords, Englisho Information Extracted:

company related tweet time self-reported location username followers count

Page 8: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Stock Market Data● Google Finance

o Stock Price by the minute

Page 9: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Processing Data● Normalize Tweets

o Lowercasedo Non-alphanumerical characters (@, $, #,

etc.)● Sentiment Analysis

o lexicon-based approacho Used SentiWordNet (

http://sentiwordnet.isti.cnr.it/)

Page 10: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Lexicon Based Approach ExplainedTweet Example:“going to mcdonald's with mah friends today and i need to know what toy i should get with my happy meal”

Positive Score Negative Score Word: know

000.12500.12500.250.250.3750.625

0000000000

know, recognize, acknowledgeknow, cognizeknowknowknowknow, live, experienceknowknowknowknow

Scores taken from SentiWordNet

Page 11: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Lexicon Based Approach ExplainedTweet Example:“going to mcdonald's with mah friends today and i need to know what toy i should get with my happy meal”

Positive Score Negative Score Word: know

000.12500.12500.250.250.3750.625Average: 0.1625

0000000000Average: 0

know, recognize, acknowledgeknow, cognizeknowknowknowknow, live, experienceknowknowknowknow

Scores taken from SentiWordNet

Page 12: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Pos Neg Word

00

00.5

goinggoing

0 0 friends

00.1250.250

0000

todaytodaytoday, nowadays, nowtoday

0.12500.0.3750.125

0.1250.2500.250.125

need, want, requireneed, involve, demand, postulateneed, motiveneedneed, demand

000.12500.12500.250.250.3750.625

0000000000

know, recognize, acknowledgeknow, cognizeknowknowknowknow, live, experienceknowknowknowknow

00.25000000

0000000.1250.125

toytoy, play, fiddle, diddletoy, play flirt dally toy_dogtoy, miniaturetoy, play thingtoytoy

000000000000.1250.5000000000.12500

0000000000.1250000000000.1250000

getget, caused, simulateget, dive, aimgetget, fix, pay_backget, catch, captureget, catchget, fetch, convey, bringget, catch, arrestgetget, drawget, catchgetget_under_ones_skinget, come, arrivegetget, get_offget, have, experienceget, receiveget, catchget, catchget, acquire get, make, haveget

0.1250.750.8750.5

0000

happyhappyhappyhappy, glad

000

000

mealmeal, repastmeal

Scores taken from SentiWordNet

Page 13: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Positive Average Negative Average Word

0.1625 0 going

0 0 friends

0.09375 0 today

0.125 0.75 need

0.175 0 know

0.03125 0.03125 toy

0.03125 0.0104166 get

0.5625 0 happy

0 0 meal

1.18125 0.7916666 Total Sentiment

Page 14: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Tweet Example: “going to mcdonald's with mah friends today and i need to know what toy i should get with my happy meal”

Positive!

Page 15: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Geographical Location● Filter out by US cities● Choose the top represented cities

assumed self-reported location is valid Used Google Maps Api to process tweets

Page 16: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Work Flow

Page 17: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Locations Found● Our Twitter Sample● Cities are highly

represented**● Does our Twitter

Sample have a high representation of the top cities?

Twitter Top Cities*

New York, NY

Washington DC

Los Angeles, CA

Chicago, IL

Dallas, TX

Top Cities (GDP)

New York, NY

Los Angeles, CA

Chicago, IL

Houston, TX

Washington DC

*Wikipedia.org

Page 18: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Results

Page 19: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Results

Page 20: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Challenges● Limited time frame● Geographic locations● Different number of tweets/stocks per

minute

Page 21: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Future Work● Larger Twitter Sample● Predicting Stock Price● Correlate the number of followers to

stock price

Page 22: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

ReferencesCities by GDP• *"List of U.S. Metropolitan Areas by GDP." Wikipedia. Wikimedia

Foundation, 22 July 2014. Web. 31 July 2014.• **Mislove, Alan, et al. "Understanding the Demographics of

Twitter Users."ICWSM 11 (2011): 5th.

Page 23: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Thank you!Faculty Advisor: Dr. Shang Yi

Graduate Student: Zhaoyu Li

REU Group & Mentors for their help and support!University of MissouriNational Science Foundation* *Award Abstract #1359125 REU: Research in Consumer Networking Technologies

Page 24: Finding Correlations Between Geographical Twitter Sentiment and Stock Prices

Questions?