Skip to content

An assignment for DSC540 (Machine Learning for Data Science) at GCU that focused on building an efficient classification model powered by the Naive Bayes algorithm. See README.md for more information.

Notifications You must be signed in to change notification settings

jhould007/DSC540-Probabilistic-Classifier-With-Naive-Bayes

Repository files navigation

DSC540-Probabilistic-Classifier-With-Naive-Bayes

An assignment for DSC540 (Machine Learning for Data Science) at GCU that focused on building an efficient classification model powered by the Naive Bayes algorithm. The specific task was to perform sentiment analysis on a dataset of tweets about ChatGPT over a 1-month period and classify them as positive, neutral, or negative.

Check out the full report here.

Assignment Instructions

Part 1

To perform sentiment analysis using a Naïve Bayes algorithm, complete the following:

  1. Access the resources related to sentiment analysis, located in the topic Resources. Note: There are about 50 datasets that are suitable for use in a sentiment analysis task. For this part of the exercise, you must choose one of these datasets, provided it includes at least 10,000 instances.
  2. Ensure that the datasets are suitable for classification using this method.
  3. You may search for data in other repositories, such as Data.gov, Kaggle or Scikit Learn.

Part 2

For your selected dataset, build a classification model as follows:

  1. Explain the dataset and the type of information you wish to gain by applying a classification method.
  2. Explain the Naïve Bayes algorithm and how you will be using it in your analysis (list the steps, the intuition behind the mathematical representation, and address its assumptions).
  3. Import the necessary libraries, then read the dataset into a data frame and perform initial statistical exploration.
  4. Clean the data and address unusual phenomena (e.g., normalization, feature scaling, outliers); use illustrative diagrams and plots and explain them.
  5. Formulate two questions that can be answered by applying a classification method using the Naïve Bayes.
  6. Choose one of the Naive Bayes types of algorithms: Gaussian Naïve Bayes, Multinomial Naïve Bayes, or Bernoulli Naïve Bayes and explain your reasoning.
  7. Split the data into dependent and independent variables (or features and labels).
  8. Vectorize the text into numbers.
  9. Train the Naïve Bayes classifier on the training set.
  10. Make classification predictions.
  11. Interpret the results in the context of the questions you asked.
  12. Validate your model using a confusion matrix, accuracy score, ROC-AUC curves, and k-fold cross validation. Then, explain the results.
  13. Include all mathematical formulas used and graphs representing the final outcomes.

Prepare a comprehensive technical report as a markdown document or Jupyter notebook, including all code, code comments, all outputs, plots, and analysis. Make sure the project documentation contains a) problem statement, b) algorithm of the solution, c) analysis of the findings, and d) deferences.

While APA style is not required for the body of this assignment, solid academic writing is expected, and documentation of sources should be presented using APA formatting guidelines, which can be found in the APA Style Guide, located in the Student Success Center.

This assignment uses a rubric. Review the rubric prior to beginning the assignment to become familiar with the expectations for successful completion.

You are not required to submit this assignment to LopesWrite.

About

An assignment for DSC540 (Machine Learning for Data Science) at GCU that focused on building an efficient classification model powered by the Naive Bayes algorithm. See README.md for more information.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published