Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/0x0be/scrapeadvisor

A user-friendly python-based GUI which provides sentiment analysis of users' reviews toward a specific TripAdvisor facility
https://github.com/0x0be/scrapeadvisor

data-mining data-science python3 r scraping sentiment-analysis sentiment-classification text-mining tripadvisor tripadvisor-scraper web-scraping

Last synced: about 1 month ago
JSON representation

A user-friendly python-based GUI which provides sentiment analysis of users' reviews toward a specific TripAdvisor facility

Awesome Lists containing this project

README

        



Project logo

scrapeadvisor

[![Status](https://img.shields.io/badge/status-active-success.svg)]()
[![License](https://img.shields.io/badge/license-GPL3-blue.svg)](/LICENSE)

---


A user-friendly python-based GUI which provides sentiment analysis of users' reviews toward a specific TripAdvisor facility


## Table of Contents

- [About](#about)
- [Getting Started](#getting_started)
- [Run](#run)
- [Usage](#usage)
- [Statistics](#statistics)
- [Supported Languages](#languages)
- [Built Using](#built_using)
- [Authors](#authors)
- [Acknowledgments](#acknowledgement)
- [Disclaimer](#disclaimer)

## About

If you're reading, dear Tripadvisor, Inc., hire me!

## Getting Started

### Prerequisites

- [Python](https://www.python.org/downloads/) installed
- [R](https://cran.r-project.org/bin/windows/base/) installed

### Installing

Make sure you've all Python dependencies installed with:

```console
scrape@advisor:~$ pip3 install -r requirements.txt
```

Also, the following R packages are needed:

- dplyr
- readr
- lubridate
- ggplot2
- tidytext
- tidyverse
- stringr
- tidyr
- scales
- broom
- purrr
- widyr
- igraph
- ggraph
- SnowballC
- wordcloud
- reshape2
- TeachingDemos

You can manually install missing ones with:

```R
install.packages("library_name")
```

or run [this script](https://github.com/blackeko/scrapeadvisor/blob/master/ipak.R) (credit to [@stevenworthington](https://gist.github.com/stevenworthington)) to install them all.

### Note

For Italian language support, **TextWiller** library must be installed.

To do that:

```R
install.packages("devtools")
install_github("livioivil/TextWiller")
```

## Run

In order to launch *scrapeadvisor* GUI, run:

```console
scrape@advisor:~$ python3 ScrapeAdvisor.py
```

## Usage

### Insert URL

1. Insert the main page URL of a TripAdvisor structure (pub/restaurant/hotel/whatever) in the **URL bar** and click **Enter** (or press Enter)
2. Wait until **"Reviews Loaded"** label appears (may take time, depending on number of reviews)

### Show Reviews

After the download is finished, press **"Show Reviews"** to see all the downloaded reviews.

### Sentiment Analysis

After the download is finished, press **"Sentiment Analysis"** button and wait: all the graphs related to the facility will appear follow after, so you can **swipe** between them.

## Statistics

- Frequent **couple/trio of consecutive words** (bigrams/trigrams)
- Most **positive/negative review**
- Top **positive/negative sentiments** of users
- The **trending/shrinking words**
- **Users' main cities**

## Screenshot








## Supported Languages

- English
- Italian

## Built Using

- [Kivy](https://kivy.org/#home) - GUI
- [Beautiful Soup](https://www.crummy.com/software/BeautifulSoup/bs4/doc/) - HTML scraping
- [R](https://www.r-project.org/about.html) - Sentiment Analysis

## Acknowledgements

- [@susanli2016](https://github.com/susanli2016) - [Web Scraping TripAdvisor](https://towardsdatascience.com/scraping-tripadvisor-text-mining-and-sentiment-analysis-for-hotel-reviews-cc4e20aef333)
- [TextWiller](https://github.com/livioivil/TextWiller) - For providing Italian stop words and lexicon
- All the other [packages](#about) - Thank you for being you

## Disclaimer

*Scrapeadvisor* is provided under this License on an AS-IS basis, **without warranty of any kind**, either expressed, implied, or statutory, including, without limitation, warranties that the *scrapeadvisor* is free of defects, merchantable, fit for a particular purpose or non-infringing.

To the extent permitted under Law, *scrapeadvisor* is provided under an AS-IS basis. The *scrapeadvisor* Team shall never, and without any limit, be liable for any damage, cost, expense or any other payment incurred as a result of *scrapeadvisor*'s actions, failure, bugs and/or any other interaction between *scrapeadvisor* and end-equipment, computers, other software or any 3rd party, end-equipment, computer or services.

We **do not encourage** running *scrapeadvisor* against Tripadvisor without prior mutual consent. The *scrapeadvisor* Team accept no liability and are not responsible for any misuse or damage caused by *scrapeadvisor*.