https://github.com/sadmansakib93/naive-bayes
Implementation of Naive Bayes from scratch using Python
https://github.com/sadmansakib93/naive-bayes
artificial-intelligence bayes-classifier classification dataset machine-learning naive-bayes naive-bayes-algorithm naive-bayes-classification naive-bayes-classifier naive-bayes-implementation predictions python test-dataset training-dataset
Last synced: 4 months ago
JSON representation
Implementation of Naive Bayes from scratch using Python
- Host: GitHub
- URL: https://github.com/sadmansakib93/naive-bayes
- Owner: SadmanSakib93
- Created: 2019-12-25T06:48:42.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2019-12-25T06:53:10.000Z (over 5 years ago)
- Last Synced: 2025-01-12T01:22:08.959Z (5 months ago)
- Topics: artificial-intelligence, bayes-classifier, classification, dataset, machine-learning, naive-bayes, naive-bayes-algorithm, naive-bayes-classification, naive-bayes-classifier, naive-bayes-implementation, predictions, python, test-dataset, training-dataset
- Language: Python
- Size: 63.5 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Naive-Bayes
Implementation of Naive Bayes from scratch using Python.* This is a python implementation of Naïve Bayes Algorithm (m-estimate version) for a binary classification problem from scratch.
* The program will take two inputs: a training dataset and a test dataset.
* The value of m will be the number of possible values of a feature.
* All features will be categorical in the dataset.
* The last column of the datasets will be the class variable.
* The two-class values as positive and negative.
* The program will first load the training dataset, calculate all required probabilities, and then predict the class of each instance in the test set.
* The program will add a new column containing predicted classes to the test dataset and save it as predictions.csv.
* The program will also show the accuracy, sensitivity, and specificity on the console