A Java implementation of the naive bayes classifier algorithm in an application to detect and filter spam and stop words.
- A visual representation of the accuracy and precision
- Shows distribution of ham(H) files and spam(S) files in training and testing phase
Where , and number of files that have
The third computation deals with rare words by putting more confidence in the spam probability than the default probability, if the word occurs more than 4 times in the training phase
Does not evaluate stop words specified in stopwords.txt
.
Stop words like "a", "the", or "is" provide little to no context to if the file is a spam. Therefore, it is optimal to not evaluate such words
git clone https://github.com/Ajmain-Khan/Naive-Bayes-Spam-Filtering
i. Navigate to Project
and add the Java 15 SDK
ii. Navigate to Global Libraries
and add JavaFX 15 to modules
i. Add an application template, modify it to direct to src.main
ii. Add VM options --module-path "path-to-lib" --add-modules javafx.controls,javafx.fxml