SlideShare a Scribd company logo
1 of 23
Sentiment Analysis
By: Gunjan Srivastava
About
Sentiment analysis is one of the Natural
Processing techniques that extracts the
emotions from the raw set of data. It is
basically applied on the news data, social
media posts, customer reviews etc to
understand the emotions of the readers or the
customers and to understand how the users
are feeling about the posts they are reading.
With the increased competitions, the customer
feedback has become very important. With the
increased and larger users opinion, reviews
and feedback, automated techniques are
required to analyse them and to take actions
accordingly.
Techniques
● Lexical analysis
● Machine learning based analysis
● Hybrid/Combined analysis
Lexical Analysis
The input text is converted to tokens by the Tokenizer and then every new token encountered is then
matched for the lexicon in the dictionary. On finding the positive match, the score is added to the
total pool of score for the input text.
An accuracy of about 80% on single phrases can be achieved by the use of hand tagged lexicons
comprised of only adjectives, which are crucial for deciding the subjectivity of an evaluative text.
Machine Learning Based Analysis
Data
Collection
Pre
Processin
g
Training
Data
Classificat
ion
Plotting
Results
Methodologies
Web
Scraping
EDA
Word
Cloud
Train
Model
Sentiment
Analysis
LDA
Topic
Modelling
Libraries
● NLTK: Python module for NLP techniques
● Vader: NLTK library used for sentiment analysis
● Gensim: Used for topic-modelling
● Scikit-learn: Python machine learning library
Web Scraping
● Scraping Reviews from Bookings.com
● The hotel I have chosen is "Hotel
Hilton," San Francisco, CA.
● The scraped data includes:
● Basic information of the reviewer and
reviews
● Rating Score
● Reviewer Name
● Reviewer's Nationality
● Overall Review (contains both
positive & negative reviews)
● Reviewer Reviewed Times
● Review Date
● Review Tags like Trip type, such as
business trip, leisure trip
● Positive reviews
● Negative reviews
Web Scraping
The negative reviews are more compared positive reviews.
Histogram representation of hotel reviews. The reviews are more negative
compared to positive reviews.
Solution
Histogram showing the reviews based on the trip type, for example: couple
trip, solo trip, family, business, etc.
Positive Review Outcome
● From the above plot, we can conclude that most people are
probably satisfied with the location, very convenient,
comfortable and close to Union Square or Chinatown.
● Easy to find restaurants or pubs nearby, friendly and helpful
staff
● Clean room, comfortable bed, and good price, etc.
WordCloud for Positive Reviews.
Negative Review Outcome
● Words like “breakfast”, “room” and “staff” are mentioned quite often, which
indicates that maybe people were complaining about the staffs who were being
rude, small rooms, and coffee/ cereal/ muffin provided during breakfast.
● The air conditioning or the shower system may need improvements as we see
words like “hot”, “cold”, “air”, “condition”, “bathroom” and “shower” in the
WordCloud.
● The hotel may also need to solve issues related to soundproofing and parking.
WordCloud for Negative Reviews.
Sentiment Analysis Outcome
The green dots that lies on the vertical line are the “neutral” reviews
The red dots on the left are the “negative” reviews
The blue dots on the right are the “positive” reviews.
Bigger dots indicate more subjectivity.
Sentiment Analysis Outcome
Model Training
GradientBoostingClassifier
GradientBoostingClassifier build trees one at a time, where each new tree helps to correct errors
made by previously trained tree. After applying the classifier, the accuracy score found is 67%
which can vary in the range of 63% to 80% depending upon the combination of the selected
features.
RandomForestClassifier
Random forest consists of a large number of individual decision trees that operate as an
ensemble. Each individual tree in the random forest spits out a class prediction and the class with
the most votes becomes the model’s prediction.
Topic Modeling
LDA model to find each document topic distribution and the high probability of word in each topic.
Here, we want to specifically look at the negative reviews to find out what aspects should the hotel be
focusing on improving.
Steps to find the optimal LDA model:
Convert the reviews to document-term matrix
GridSearch and tune for the optimal LDA model
Output the optimal lda model and its parameters
Compare LDA Model Performance Scores
Topic Modeling
From the graph, we see that there is little impact to choose different learning decay.
5 topics would produce the best model.
Conclusion
● The train dataset used to train the model provides a good prediction for the hotel reviews whether they
are positive, negative, very positive or very negative.
● The accuracy of the prediction is around 70% which is considered good.
● From the Sentiment Analysis scatter plot, we see that positive reviews are slightly more than the
negatives.
● Hotel Hilton definitely needs to improve hotel guest satisfaction.
● The WordCloud reveals some problems for the hotel manager to look into, like their breakfast.
● The hotel manager should train staff well to provide friendlier and better services.
● The hotel may also need to work with issues related to soundproofing, air conditioning, shower system
and parking.
● The EDA section could give the hotel manager a general idea of the reviews as well as the rating
distribution.
● The pyLDAvis interactive visualization would help the hotel manager to further understand what most
popular topics within the negative reviews are and make improvements accordingly.
Thank You

More Related Content

What's hot

Sentiment Analysis using Twitter Data
Sentiment Analysis using Twitter DataSentiment Analysis using Twitter Data
Sentiment Analysis using Twitter DataHari Prasad
 
Presentation on Sentiment Analysis
Presentation on Sentiment AnalysisPresentation on Sentiment Analysis
Presentation on Sentiment AnalysisRebecca Williams
 
Sentiment Analysis
Sentiment AnalysisSentiment Analysis
Sentiment AnalysisAditya Nag
 
Social Media Sentiments Analysis
Social Media Sentiments AnalysisSocial Media Sentiments Analysis
Social Media Sentiments AnalysisPratisthaSingh5
 
Sentiment analysis
Sentiment analysisSentiment analysis
Sentiment analysisSeher Can
 
Sentiment Analysis of Twitter Data
Sentiment Analysis of Twitter DataSentiment Analysis of Twitter Data
Sentiment Analysis of Twitter DataSumit Raj
 
Sentiment Analaysis on Twitter
Sentiment Analaysis on TwitterSentiment Analaysis on Twitter
Sentiment Analaysis on TwitterNitish J Prabhu
 
Amazon Product Sentiment review
Amazon Product Sentiment reviewAmazon Product Sentiment review
Amazon Product Sentiment reviewLalit Jain
 
Sentiment Analysis
Sentiment AnalysisSentiment Analysis
Sentiment AnalysisAnkur Tyagi
 
Sentiment Analysis Using Twitter
Sentiment Analysis Using TwitterSentiment Analysis Using Twitter
Sentiment Analysis Using Twitterpiya chauhan
 
Twitter sentiment analysis ppt
Twitter sentiment analysis pptTwitter sentiment analysis ppt
Twitter sentiment analysis pptSonuCreation
 
Sentiment analysis
Sentiment analysisSentiment analysis
Sentiment analysisAmenda Joy
 
Sentiment analysis of twitter data
Sentiment analysis of twitter dataSentiment analysis of twitter data
Sentiment analysis of twitter dataBhagyashree Deokar
 
How Sentiment Analysis works
How Sentiment Analysis worksHow Sentiment Analysis works
How Sentiment Analysis worksCJ Jenkins
 
Twitter sentiment-analysis Jiit2013-14
Twitter sentiment-analysis Jiit2013-14Twitter sentiment-analysis Jiit2013-14
Twitter sentiment-analysis Jiit2013-14Rachit Goel
 
Sentiment analysis of Twitter data using python
Sentiment analysis of Twitter data using pythonSentiment analysis of Twitter data using python
Sentiment analysis of Twitter data using pythonHetu Bhavsar
 
social network analysis project twitter sentimental analysis
social network analysis project twitter sentimental analysissocial network analysis project twitter sentimental analysis
social network analysis project twitter sentimental analysisAshish Mundra
 
Text classification & sentiment analysis
Text classification & sentiment analysisText classification & sentiment analysis
Text classification & sentiment analysisM. Atif Qureshi
 

What's hot (20)

Sentiment Analysis using Twitter Data
Sentiment Analysis using Twitter DataSentiment Analysis using Twitter Data
Sentiment Analysis using Twitter Data
 
Presentation on Sentiment Analysis
Presentation on Sentiment AnalysisPresentation on Sentiment Analysis
Presentation on Sentiment Analysis
 
Sentiment Analysis
Sentiment AnalysisSentiment Analysis
Sentiment Analysis
 
Social Media Sentiments Analysis
Social Media Sentiments AnalysisSocial Media Sentiments Analysis
Social Media Sentiments Analysis
 
Sentiment analysis
Sentiment analysisSentiment analysis
Sentiment analysis
 
Sentiment analysis
Sentiment analysisSentiment analysis
Sentiment analysis
 
Sentiment Analysis of Twitter Data
Sentiment Analysis of Twitter DataSentiment Analysis of Twitter Data
Sentiment Analysis of Twitter Data
 
Amazon seniment
Amazon senimentAmazon seniment
Amazon seniment
 
Sentiment Analaysis on Twitter
Sentiment Analaysis on TwitterSentiment Analaysis on Twitter
Sentiment Analaysis on Twitter
 
Amazon Product Sentiment review
Amazon Product Sentiment reviewAmazon Product Sentiment review
Amazon Product Sentiment review
 
Sentiment Analysis
Sentiment AnalysisSentiment Analysis
Sentiment Analysis
 
Sentiment Analysis Using Twitter
Sentiment Analysis Using TwitterSentiment Analysis Using Twitter
Sentiment Analysis Using Twitter
 
Twitter sentiment analysis ppt
Twitter sentiment analysis pptTwitter sentiment analysis ppt
Twitter sentiment analysis ppt
 
Sentiment analysis
Sentiment analysisSentiment analysis
Sentiment analysis
 
Sentiment analysis of twitter data
Sentiment analysis of twitter dataSentiment analysis of twitter data
Sentiment analysis of twitter data
 
How Sentiment Analysis works
How Sentiment Analysis worksHow Sentiment Analysis works
How Sentiment Analysis works
 
Twitter sentiment-analysis Jiit2013-14
Twitter sentiment-analysis Jiit2013-14Twitter sentiment-analysis Jiit2013-14
Twitter sentiment-analysis Jiit2013-14
 
Sentiment analysis of Twitter data using python
Sentiment analysis of Twitter data using pythonSentiment analysis of Twitter data using python
Sentiment analysis of Twitter data using python
 
social network analysis project twitter sentimental analysis
social network analysis project twitter sentimental analysissocial network analysis project twitter sentimental analysis
social network analysis project twitter sentimental analysis
 
Text classification & sentiment analysis
Text classification & sentiment analysisText classification & sentiment analysis
Text classification & sentiment analysis
 

Similar to Sentiment Analysis of Hotel Reviews

Yelp Product Challenge
Yelp Product ChallengeYelp Product Challenge
Yelp Product ChallengeHisham Radwan
 
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?How Does Customer Feedback Sentiment Analysis Work in Search Marketing?
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?Countants
 
IRJET- Opinion Targets and Opinion Words Extraction for Online Reviews wi...
IRJET-  	  Opinion Targets and Opinion Words Extraction for Online Reviews wi...IRJET-  	  Opinion Targets and Opinion Words Extraction for Online Reviews wi...
IRJET- Opinion Targets and Opinion Words Extraction for Online Reviews wi...IRJET Journal
 
IRJET- Fake Review Detection using Opinion Mining
IRJET- Fake Review Detection using Opinion MiningIRJET- Fake Review Detection using Opinion Mining
IRJET- Fake Review Detection using Opinion MiningIRJET Journal
 
IRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment AnalysisIRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment AnalysisIRJET Journal
 
Deep Dive - Consumer Sentiment Rating & Analysis White Paper
Deep Dive - Consumer Sentiment Rating & Analysis White PaperDeep Dive - Consumer Sentiment Rating & Analysis White Paper
Deep Dive - Consumer Sentiment Rating & Analysis White PaperJon LeMire
 
GA – Client Project General Guidelines Mgmt5074 Fanshaw.docx
GA – Client Project General Guidelines Mgmt5074  Fanshaw.docxGA – Client Project General Guidelines Mgmt5074  Fanshaw.docx
GA – Client Project General Guidelines Mgmt5074 Fanshaw.docxhanneloremccaffery
 
How to Build Legendary Customer Relationships With Artificial Intelligence
How to Build Legendary Customer Relationships With Artificial IntelligenceHow to Build Legendary Customer Relationships With Artificial Intelligence
How to Build Legendary Customer Relationships With Artificial IntelligenceChristopher Mohritz
 
Customer_Analysis.docx
Customer_Analysis.docxCustomer_Analysis.docx
Customer_Analysis.docxKevalKabariya
 
Lead Scoring Case Study
Lead Scoring Case StudyLead Scoring Case Study
Lead Scoring Case StudyLumbiniSardare
 
10 Things to Know about Net Promoter ScoresPRES
10 Things to Know about Net Promoter ScoresPRES10 Things to Know about Net Promoter ScoresPRES
10 Things to Know about Net Promoter ScoresPRESEd Smith
 
Customer review using sentiment analysis.pptx
Customer review using sentiment analysis.pptxCustomer review using sentiment analysis.pptx
Customer review using sentiment analysis.pptxTarunKalkar
 
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSSentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSIRJET Journal
 
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSSentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSIRJET Journal
 
How to Get Five Star Rating in Reflection Paper Assignment
How to Get Five Star Rating in Reflection Paper AssignmentHow to Get Five Star Rating in Reflection Paper Assignment
How to Get Five Star Rating in Reflection Paper AssignmentLesa Cote
 
Operational Risk Management: Standard Requirements
Operational Risk Management: Standard RequirementsOperational Risk Management: Standard Requirements
Operational Risk Management: Standard RequirementsGerardus Blokdyk
 
Final presentation
Final presentationFinal presentation
Final presentationBrandon Hill
 
Measuring the Quality of IT Support
Measuring the Quality of IT SupportMeasuring the Quality of IT Support
Measuring the Quality of IT SupportDave O'Reardon
 

Similar to Sentiment Analysis of Hotel Reviews (20)

Yelp Product Challenge
Yelp Product ChallengeYelp Product Challenge
Yelp Product Challenge
 
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?How Does Customer Feedback Sentiment Analysis Work in Search Marketing?
How Does Customer Feedback Sentiment Analysis Work in Search Marketing?
 
IRJET- Opinion Targets and Opinion Words Extraction for Online Reviews wi...
IRJET-  	  Opinion Targets and Opinion Words Extraction for Online Reviews wi...IRJET-  	  Opinion Targets and Opinion Words Extraction for Online Reviews wi...
IRJET- Opinion Targets and Opinion Words Extraction for Online Reviews wi...
 
IRJET- Fake Review Detection using Opinion Mining
IRJET- Fake Review Detection using Opinion MiningIRJET- Fake Review Detection using Opinion Mining
IRJET- Fake Review Detection using Opinion Mining
 
IRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment AnalysisIRJET- Survey of Classification of Business Reviews using Sentiment Analysis
IRJET- Survey of Classification of Business Reviews using Sentiment Analysis
 
Leila 2
Leila 2Leila 2
Leila 2
 
Leila 2
Leila 2Leila 2
Leila 2
 
Deep Dive - Consumer Sentiment Rating & Analysis White Paper
Deep Dive - Consumer Sentiment Rating & Analysis White PaperDeep Dive - Consumer Sentiment Rating & Analysis White Paper
Deep Dive - Consumer Sentiment Rating & Analysis White Paper
 
GA – Client Project General Guidelines Mgmt5074 Fanshaw.docx
GA – Client Project General Guidelines Mgmt5074  Fanshaw.docxGA – Client Project General Guidelines Mgmt5074  Fanshaw.docx
GA – Client Project General Guidelines Mgmt5074 Fanshaw.docx
 
How to Build Legendary Customer Relationships With Artificial Intelligence
How to Build Legendary Customer Relationships With Artificial IntelligenceHow to Build Legendary Customer Relationships With Artificial Intelligence
How to Build Legendary Customer Relationships With Artificial Intelligence
 
Customer_Analysis.docx
Customer_Analysis.docxCustomer_Analysis.docx
Customer_Analysis.docx
 
Lead Scoring Case Study
Lead Scoring Case StudyLead Scoring Case Study
Lead Scoring Case Study
 
10 Things to Know about Net Promoter ScoresPRES
10 Things to Know about Net Promoter ScoresPRES10 Things to Know about Net Promoter ScoresPRES
10 Things to Know about Net Promoter ScoresPRES
 
Customer review using sentiment analysis.pptx
Customer review using sentiment analysis.pptxCustomer review using sentiment analysis.pptx
Customer review using sentiment analysis.pptx
 
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSSentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
 
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRSSentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
Sentiment Analysis of Product Reviews and Trustworthiness Evaluation using TRS
 
How to Get Five Star Rating in Reflection Paper Assignment
How to Get Five Star Rating in Reflection Paper AssignmentHow to Get Five Star Rating in Reflection Paper Assignment
How to Get Five Star Rating in Reflection Paper Assignment
 
Operational Risk Management: Standard Requirements
Operational Risk Management: Standard RequirementsOperational Risk Management: Standard Requirements
Operational Risk Management: Standard Requirements
 
Final presentation
Final presentationFinal presentation
Final presentation
 
Measuring the Quality of IT Support
Measuring the Quality of IT SupportMeasuring the Quality of IT Support
Measuring the Quality of IT Support
 

Recently uploaded

Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomnelietumpap1
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........LeaCamillePacle
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceSamikshaHamane
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptxSherlyMaeNeri
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfphamnguyenenglishnb
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxDr.Ibrahim Hassaan
 

Recently uploaded (20)

Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Raw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptxRaw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptx
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choom
 
Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........Atmosphere science 7 quarter 4 .........
Atmosphere science 7 quarter 4 .........
 
Roles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in PharmacovigilanceRoles & Responsibilities in Pharmacovigilance
Roles & Responsibilities in Pharmacovigilance
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
Rapple "Scholarly Communications and the Sustainable Development Goals"
Rapple "Scholarly Communications and the Sustainable Development Goals"Rapple "Scholarly Communications and the Sustainable Development Goals"
Rapple "Scholarly Communications and the Sustainable Development Goals"
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptx
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdfAMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
AMERICAN LANGUAGE HUB_Level2_Student'sBook_Answerkey.pdf
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
Gas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptxGas measurement O2,Co2,& ph) 04/2024.pptx
Gas measurement O2,Co2,& ph) 04/2024.pptx
 

Sentiment Analysis of Hotel Reviews

  • 2. About Sentiment analysis is one of the Natural Processing techniques that extracts the emotions from the raw set of data. It is basically applied on the news data, social media posts, customer reviews etc to understand the emotions of the readers or the customers and to understand how the users are feeling about the posts they are reading. With the increased competitions, the customer feedback has become very important. With the increased and larger users opinion, reviews and feedback, automated techniques are required to analyse them and to take actions accordingly.
  • 3. Techniques ● Lexical analysis ● Machine learning based analysis ● Hybrid/Combined analysis
  • 4. Lexical Analysis The input text is converted to tokens by the Tokenizer and then every new token encountered is then matched for the lexicon in the dictionary. On finding the positive match, the score is added to the total pool of score for the input text. An accuracy of about 80% on single phrases can be achieved by the use of hand tagged lexicons comprised of only adjectives, which are crucial for deciding the subjectivity of an evaluative text.
  • 5. Machine Learning Based Analysis Data Collection Pre Processin g Training Data Classificat ion Plotting Results
  • 7. Libraries ● NLTK: Python module for NLP techniques ● Vader: NLTK library used for sentiment analysis ● Gensim: Used for topic-modelling ● Scikit-learn: Python machine learning library
  • 8. Web Scraping ● Scraping Reviews from Bookings.com ● The hotel I have chosen is "Hotel Hilton," San Francisco, CA. ● The scraped data includes: ● Basic information of the reviewer and reviews ● Rating Score ● Reviewer Name ● Reviewer's Nationality ● Overall Review (contains both positive & negative reviews) ● Reviewer Reviewed Times ● Review Date ● Review Tags like Trip type, such as business trip, leisure trip ● Positive reviews ● Negative reviews
  • 10. The negative reviews are more compared positive reviews.
  • 11. Histogram representation of hotel reviews. The reviews are more negative compared to positive reviews. Solution
  • 12. Histogram showing the reviews based on the trip type, for example: couple trip, solo trip, family, business, etc.
  • 13. Positive Review Outcome ● From the above plot, we can conclude that most people are probably satisfied with the location, very convenient, comfortable and close to Union Square or Chinatown. ● Easy to find restaurants or pubs nearby, friendly and helpful staff ● Clean room, comfortable bed, and good price, etc.
  • 15. Negative Review Outcome ● Words like “breakfast”, “room” and “staff” are mentioned quite often, which indicates that maybe people were complaining about the staffs who were being rude, small rooms, and coffee/ cereal/ muffin provided during breakfast. ● The air conditioning or the shower system may need improvements as we see words like “hot”, “cold”, “air”, “condition”, “bathroom” and “shower” in the WordCloud. ● The hotel may also need to solve issues related to soundproofing and parking.
  • 17. Sentiment Analysis Outcome The green dots that lies on the vertical line are the “neutral” reviews The red dots on the left are the “negative” reviews The blue dots on the right are the “positive” reviews. Bigger dots indicate more subjectivity.
  • 19. Model Training GradientBoostingClassifier GradientBoostingClassifier build trees one at a time, where each new tree helps to correct errors made by previously trained tree. After applying the classifier, the accuracy score found is 67% which can vary in the range of 63% to 80% depending upon the combination of the selected features. RandomForestClassifier Random forest consists of a large number of individual decision trees that operate as an ensemble. Each individual tree in the random forest spits out a class prediction and the class with the most votes becomes the model’s prediction.
  • 20. Topic Modeling LDA model to find each document topic distribution and the high probability of word in each topic. Here, we want to specifically look at the negative reviews to find out what aspects should the hotel be focusing on improving. Steps to find the optimal LDA model: Convert the reviews to document-term matrix GridSearch and tune for the optimal LDA model Output the optimal lda model and its parameters Compare LDA Model Performance Scores
  • 21. Topic Modeling From the graph, we see that there is little impact to choose different learning decay. 5 topics would produce the best model.
  • 22. Conclusion ● The train dataset used to train the model provides a good prediction for the hotel reviews whether they are positive, negative, very positive or very negative. ● The accuracy of the prediction is around 70% which is considered good. ● From the Sentiment Analysis scatter plot, we see that positive reviews are slightly more than the negatives. ● Hotel Hilton definitely needs to improve hotel guest satisfaction. ● The WordCloud reveals some problems for the hotel manager to look into, like their breakfast. ● The hotel manager should train staff well to provide friendlier and better services. ● The hotel may also need to work with issues related to soundproofing, air conditioning, shower system and parking. ● The EDA section could give the hotel manager a general idea of the reviews as well as the rating distribution. ● The pyLDAvis interactive visualization would help the hotel manager to further understand what most popular topics within the negative reviews are and make improvements accordingly.