# NaivePy








</br>

# This Module Is No Longer Maintained
v1.1 is the last release.
# Naive Bayes :
## About Naive Bayes :
<p align="Justify">
Naïve Bayes algorithm is a supervised learning algorithm, which is based on Bayes theorem and used for solving classification problems.</br>
It is mainly used in text classification that includes a high-dimensional training dataset.</br>
Naïve Bayes Classifier is one of the simple and most effective Classification algorithms which helps in building the fast machine learning models that can make quick predictions.</br>
It is a probabilistic classifier, which means it predicts on the basis of the probability of an object.</br>
Some popular examples of Naïve Bayes Algorithm are spam filtration, Sentimental analysis, and classifying articles.
</p>
## Formula Of Naive Bayes :
<p align="justify">
Bayes' theorem is also known as Bayes' Rule or Bayes' law, which is used to determine the probability of a hypothesis with prior knowledge. It depends on the conditional probability.
The formula for Bayes' theorem is given as:
Naïve Bayes Classifier Algorithm
Where,
**$P(A|B)$ = ${P(B|A)P(A)} \over P(B)$**
P(A|B) is Posterior probability: Probability of hypothesis A on the observed event B.
P(B|A) is Likelihood probability: Probability of the evidence given that the probability of a hypothesis is true.
P(A) is Prior Probability: Probability of hypothesis before observing the evidence.
P(B) is Marginal Probability: Probability of Evidence.
</p>
# Documentation:
Read the [Docs Here](https://naivepy.readthedocs.io/en/latest/#)
# Installation :
To Install the module
```
pip install naivepy
```
# About Module:
<p align="justify">
Naivepy module is built using python and pandas. It is and machine learning algorithm. This Module can take the target column and classifies it.
**Note** : The Target Column must have 2 Types of values other wise MaxTargetColumnException will be occured.
# Examples :
**Code** :
```
from naivepy import Naive
n=Naive(filename="data.csv",sample_list=["red","suv","domestic"],target_column="stolen")
print(n.getans)
print(n.getdata)
print(n.getlabel)
```
**Output** :
```
Color Type Origin Stolen
0 Red Sports Domestic Yes
1 Red Sports Domestic No
2 Red Sports Domestic Yes
3 Yellow Sports Domestic No
4 Yellow Sports Imported Yes
5 Yellow SUV Imported No
6 Yellow SUV Imported Yes
7 Yellow SUV Domestic No
8 Red SUV Imported No
9 Red Sports Imported Yes
No
0.072
```
# Author : Prathamesh Dhande
Raw data
{
"_id": null,
"home_page": "https://github.com/PrathameshDhande22/NaivePY",
"name": "naivepy",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "naive,naive bayes,algorithm,naive algorithm,classification,module",
"author": "Prathamesh Dhande",
"author_email": "prathameshdhande534@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/5c/1d/9c207768dd616c95ceddc04dee76370e205eea82c189d571e895538da439/naivepy-1.1.tar.gz",
"platform": null,
"description": "# NaivePy\n\n \n \n \n\n \n \n\n \n\n \n\n</br>\n\n\n\n# This Module Is No Longer Maintained\nv1.1 is the last release.\n\n# Naive Bayes :\n## About Naive Bayes :\n<p align=\"Justify\">\nNa\u00efve Bayes algorithm is a supervised learning algorithm, which is based on Bayes theorem and used for solving classification problems.</br>\nIt is mainly used in text classification that includes a high-dimensional training dataset.</br>\nNa\u00efve Bayes Classifier is one of the simple and most effective Classification algorithms which helps in building the fast machine learning models that can make quick predictions.</br>\nIt is a probabilistic classifier, which means it predicts on the basis of the probability of an object.</br>\nSome popular examples of Na\u00efve Bayes Algorithm are spam filtration, Sentimental analysis, and classifying articles.\n</p>\n\n## Formula Of Naive Bayes :\n<p align=\"justify\">\nBayes' theorem is also known as Bayes' Rule or Bayes' law, which is used to determine the probability of a hypothesis with prior knowledge. It depends on the conditional probability.\nThe formula for Bayes' theorem is given as:\nNa\u00efve Bayes Classifier Algorithm\nWhere,\n\n**$P(A|B)$ = ${P(B|A)P(A)} \\over P(B)$**\n\nP(A|B) is Posterior probability: Probability of hypothesis A on the observed event B.\n\nP(B|A) is Likelihood probability: Probability of the evidence given that the probability of a hypothesis is true.\n\nP(A) is Prior Probability: Probability of hypothesis before observing the evidence.\n\nP(B) is Marginal Probability: Probability of Evidence.\n</p>\n\n# Documentation:\nRead the [Docs Here](https://naivepy.readthedocs.io/en/latest/#)\n\n# Installation :\nTo Install the module\n```\npip install naivepy\n```\n\n# About Module:\n<p align=\"justify\">\nNaivepy module is built using python and pandas. It is and machine learning algorithm. This Module can take the target column and classifies it.\n\n**Note** : The Target Column must have 2 Types of values other wise MaxTargetColumnException will be occured.\n\n# Examples :\n\n**Code** :\n```\nfrom naivepy import Naive\n\nn=Naive(filename=\"data.csv\",sample_list=[\"red\",\"suv\",\"domestic\"],target_column=\"stolen\")\nprint(n.getans)\nprint(n.getdata)\nprint(n.getlabel)\n```\n\n**Output** :\n```\n Color Type Origin Stolen\n 0 Red Sports Domestic Yes\n 1 Red Sports Domestic No\n 2 Red Sports Domestic Yes\n 3 Yellow Sports Domestic No\n 4 Yellow Sports Imported Yes\n 5 Yellow SUV Imported No\n 6 Yellow SUV Imported Yes\n 7 Yellow SUV Domestic No\n 8 Red SUV Imported No\n 9 Red Sports Imported Yes\n No\n 0.072\n```\n\n# Author : Prathamesh Dhande\n",
"bugtrack_url": null,
"license": "",
"summary": "Naive Algorithm Module Implemented in Python",
"version": "1.1",
"split_keywords": [
"naive",
"naive bayes",
"algorithm",
"naive algorithm",
"classification",
"module"
],
"urls": [
{
"comment_text": "",
"digests": {
"md5": "f167a004867b77669daefbed87ab25b3",
"sha256": "f516ab7a35a16cc8e4cc2b1aa60a96dc2d68df931c4a0a521b582e389566a88b"
},
"downloads": -1,
"filename": "naivepy-1.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f167a004867b77669daefbed87ab25b3",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 16592,
"upload_time": "2022-12-10T16:16:58",
"upload_time_iso_8601": "2022-12-10T16:16:58.611514Z",
"url": "https://files.pythonhosted.org/packages/8f/f4/a5a2661e4523aa2c4c53c1c53104f9bad94dbe66f6d84229bfea5c94a595/naivepy-1.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"md5": "9901cbb5ecd0f77e336b126392a03441",
"sha256": "cbba948e4b8686ce65e16651f0b89e6fd8e3783b85d5afa18dd37b30d8230647"
},
"downloads": -1,
"filename": "naivepy-1.1.tar.gz",
"has_sig": false,
"md5_digest": "9901cbb5ecd0f77e336b126392a03441",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 16266,
"upload_time": "2022-12-10T16:16:59",
"upload_time_iso_8601": "2022-12-10T16:16:59.744561Z",
"url": "https://files.pythonhosted.org/packages/5c/1d/9c207768dd616c95ceddc04dee76370e205eea82c189d571e895538da439/naivepy-1.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2022-12-10 16:16:59",
"github": true,
"gitlab": false,
"bitbucket": false,
"github_user": "PrathameshDhande22",
"github_project": "NaivePY",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "naivepy"
}