Home Page > > Details

NLP Assignment ,Python Programming AssignmentHelp With , Sentiment Analysis Assignment,Help With Python Course AssignmentDebug Matlab Programming|Help With Pytho

NLP Homework 4
Sentiment Analysis of Amazon Product Reviews
It is increasingly common that Internet users engage in various of online reviews. The availability of these
review content offers researchers opportunities to better understand and model online social behavior. In this
homework, you will conduct sentiment analysis to gain some understanding about the Amazon product
reviews.
1. Dataset
In this problem, you will analyze the review contents from Amazon Product Data provided by Julian McAuley
at http://jmcauley.ucsd.edu/data/amazon/. This dataset contains product reviews and metadata from Amazon,
including 142.8 million reviews spanning May 1996 – July 2014. It includes reviews (ratings, text, helpfulness
votes), product metadata (descriptions, category information, price, brand, and image features), and links (also
viewed/also bought graphs).
For our tasks, we will use only 5-core subsets of three categories (Baby / Clothing, Shoes and Jewelry / Health
and Personal Care). 5-core subsets mean that all users and items in the dataset have at least 5 reviews.
Originally, the dataset was a zipped file of json format and the content was arranged in dictionaries. For your
convenience, the dataset was modified into text file and is available for download in the Assignment folder in
the course web site: Baby.txt and clothing_shoes_jewelry.txt. You should choose one of them for the analysis.
Here are the screenshots of a raw data and a modified review file:
2
Fig 1. Raw data
Fig 2. Modified review file used for the task
- reviewerID:ID of the reviewer
- asin: ID of the product
- reviewerName: name of thereviewer
- helpful: helpfulness rating of the review, e.g. 2/3
- reviewText: text of theproduct
- overall: rating of theproduct
- summary: summary of thereview
- unixReviewTime: time of the review (unix time)
- reviewTime: time of the review (raw)
2. Data Pre-processing (20%)
You will write a Python code that extracts only review texts. Please submit the sample screenshot of the
output (included in your report file).
3. Sentiment Analysis (80%)
Based on what we have learned from this class, you will explore the sentiment of the comments at the
3
sentence level. This includes how to process the words and how to conduct the sentiment analysis using
classifiers. Ultimately, you will provide two lists of sentences: one is marked as negative and the other as
positive, your Python code and screenshot, and your report.
In your report, please explain in detail the processing techniques that you have applied, the features you used
for the classification task, and your experiments. For the data preprocessing/cleaning task, we have learned
about several techniques such as tokenization, sentence creation, regular expression processing, stop word
filtering, etc. You should describe the techniques you used in this assignment.
For the classification task and the experiments, you should start with the “bag-of-words” features where you
collect all the words in the sentence_polarity corpus and select some number of most frequent words to be the
word features. You should use at least NaiveBayes classifier to train and test a classifier on your feature sets.
If possible, i.e., if time and space permit, you should use cross-validation to obtain precision, recall, and Fmeasure
scores. In your experiments, you should use at least two different sets of features and compare the
results. For example, you may take the unigram word features as a baseline and see if the features you
designed improve the accuracy of the classification. Here are some of the types of experiments that we have
done so far:
 Filter by stop words or other pre-processing methods
 Representing negation
 Using a sentiment lexicon with scores or counts: Subjectivity
4. Bonus Credit (10%)
You do not need to work on the following tast, but if you do and do well, you will have 10% bonus credit for
this assignment.
Choose an additional, more advanced type of task from this list, or propose your own
 Using Weka or SciKit Learn classifiers with features produced in NLTK
 Using an additional type of lexicon besides Subjectivity
 Implement additional features
The student with the best performance will be invited to participate in a research project with the instructor
and/or co-author a paper related to NLP analysis of the Amazon product reviews.
How to Submit Homework:
Go to the Blackboard system and the Assignment for Homework 4. Attach your report file and submit. Your
submission should include:
1) your report in a PDF format
2) Table including two lists of sentences: negative vs positive (Please include in your report)
3) Your Python code and the processing screenshots (Please submit in one separate folder zipped)

Contact Us - Email:99515681@qq.com    WeChat:codinghelp
Programming Assignment Help!