Questions tagged [naive-bayes]

A naive Bayes classifier is a simple probabilistic classifier based on applying Bayes' theorem with strong independence assumptions. A more descriptive term for the underlying probability model would be "independent feature model".

Filter by
Sorted by
Tagged with
1 vote
0 answers
13 views

Design for using Naive Bayes to show meaningful decrease in heart rate after listening to music

Hypothesis I'm interested in using Naive Bayes to train a predictor on if listening to a certain song is likely to lower that user's heart rate to a certain threshold. More specifically, what set of ...
user avatar
  • 11
2 votes
1 answer
49 views

AUC - Logistic Regression versus LDA, and Naive Bayes

everyone! I am a newbie on machine learning, and I am now interested on classification modeling. I used logistic regression, linear discriminant analysis (LDA), and naive Bayes on my notebook DataCamp ...
user avatar
0 votes
0 answers
11 views

Minimize risk and add rejection to model

I want to minimize the risk of a Gaussian model with a cost for false negatives and false positives. The model uses Naive Bayes algorithm and solves a binary classification problem: $$P(x_i \mid y) = \...
user avatar
  • 1
0 votes
0 answers
34 views

NaiveBayes in R - Understand importance of Variables

I am working with a data set where the response variable is binary and 15-20 continuous and categorical variables. I am using the naiveBayes library to compute the model. I am interested in ...
user avatar
0 votes
1 answer
56 views

How to handle missing values NaiveBayes Scikit Learn

I am working with a dataset which has 34 features (numerical, nominal) and the target class. Several of the columns have missing values, especially one column has approximately 50% missing values. I ...
user avatar
  • 1
0 votes
0 answers
6 views

Find conditional independence between the attributes of a categorical dataset

I have a high dimensional data set. I used feature selection method to reduce the dimensionality of the dataset. Originally, the dataset has 120 attributes which I minimized to 80 attributes after ...
user avatar
  • 121
0 votes
0 answers
22 views

Why are linear/logistic regression and naive bayes called "parametric" while SVM, random forests, neural nets are not? [duplicate]

This table is mentioned in What algorithms need feature scaling, beside from SVM? It says that linear regression, logistic regression, and naive bayes are parametric, while KNN, decision trees, ...
user avatar
  • 31
1 vote
1 answer
10 views

Impact of Laplace smoothing on likelihood in Naive Bayes

When 1 is added to word count in Laplace Smoothing in Naive Bayes, the new probabilities either increase or decrease as shown below. Though the problem of "zero" probability has been solved. ...
user avatar
0 votes
0 answers
8 views

How to go about using one machine learning method to 'augment' another?

I'm in a machine learning class, and we've been asked to create some sort of... machine learning solution to a problem, using two different forms of machine learning. I'm doing something pretty basic, ...
user avatar
  • 101
0 votes
1 answer
29 views

Use Naive Bayes to label unlabeled data

I have an Excel file that includes all product information (web scraped from Zalando) of 10k dresses. So for each dress/line I have multiple features available (brand, color, neckline, length...) I ...
user avatar
0 votes
0 answers
8 views

Why would including a feature reduce performance of Naive Bayes (multi class prediction)

I have a simple Naive Bayes model, 5 features, trying to classify observations into 1 of 3 classes. I add a 6th feature and the test set performance, from 58% correct classified to 54% correctly ...
user avatar
0 votes
1 answer
46 views

Naive-Bayes Iris R, Correct Implementation? [closed]

So I am trying to understand the naive Bayes classifier by implementing it in R. However I'm not sure if my implementation is correct. Using the iris dataset and Sepal Width / Length as features. ...
user avatar
1 vote
0 answers
14 views

Log Naive Bayes NLP dropping the denominator [duplicate]

I'm learning about the the Naive Bayes classification and I don't get what the squiggly alpha sign means and what it means that "Denominator remains constant for given input." Is it because ...
user avatar
0 votes
1 answer
91 views

Computing a prior from two components in Naive Bayes

Given a model parameter $\theta$ that is composed of two distributions in a Naive Bayes classifier, how is $P(\theta)$ typically computed in practice? More specifically, from the article of Nigam et ...
user avatar
0 votes
0 answers
61 views

Negative Log Likelihood and Derivative of Gaussian Naive Bayes Classifer

I am trying to derive negative log likelihood of Gaussian Naive Bayes classifier and the derivatives of the parameters. So there are class labels $y \in {1, ..., k}$, and real valued vector of $d$ ...
user avatar
  • 1
0 votes
0 answers
18 views

How to improve accuracy of natural's Naive Bayes classifier?

Note: I'm new to Machine Learning and NLP. This is my first project in this field. I'm using NaturalNode/natural (https://github.com/NaturalNode/natural) to build a chat bot to help my users with ...
user avatar
1 vote
0 answers
13 views

Laplace Smoothing in Naive Bayes [duplicate]

I'm reading up on Laplace Smoothing/Add-1 Smoothing in Naive Bayes and I'm given the formula $ \frac{Count(Feature=Value) + α}{N + α\cdot k} $. In reference to the image above, if we have to classify ...
user avatar
1 vote
0 answers
13 views

Oscillation of AdaBoost Training error

Adaboost, using weak learners as Gaussian Naive bayes, has oscillating/unpredictable training error as we increase the number of weak learners. Is there a specific reason for this? Y-axis is the ...
user avatar
  • 11
2 votes
1 answer
73 views

What attributes does Laplace Smoothing apply on in Naive Bayes

Consider the dataset: Outlook Temperature Humidity Play Golf? Overcast Cool Low Yes Sunny Hot Low Yes Rainy Cool High No Sunny Hot High No Rainy Cool Low Yes There are 3 possible values for the ...
user avatar
0 votes
0 answers
18 views

What is the $\prod_{i=1}^dP(x_i|y=1)$ in the Naive Bayes classifier?

Consider the Naive Bayes classifier. Suppose that $x=(x_1, x_2, \dots, x_d)^T$ and $x_i\in \{0, 1\}$ with labels $y_i\in \{0,1\}$. Let $P(y=1)=p=1-P(y=0)$ and $P(x_i=1|y=0)=p_{i0}$, $P(x_i=1|y=1)=p_{...
user avatar
  • 262
0 votes
0 answers
29 views

Two models trained on the same data, with very similar performance statistics, give very different results on unseen data

I am trying to develop a natural language processing model. My goal is to be simple, and basically say if something is good or bad for a topic. I have a training set made up of around 15000 sentences. ...
user avatar
1 vote
0 answers
33 views

How do you interpret the matrix confusion in this Naïve Bayes output?

Why are my correctly classified instances lower than incorrectly classified? This was tested using Naive Bayes with option testing Cross-Validation set at 10 folds. Here is the image of the results: ...
user avatar
  • 11
1 vote
0 answers
110 views

How to calculate the Bayesian Risk Classifier

I'm not exactly sure how to calculate the Bayesian risk Classifier $L(r^*)$ for $Y\in\{ 0,1 \}$. For this scenario, assume: $X\in\mathbb{X}=[0,1],Y\in\{ 0,1 \}$ $\pi_y=P(Y=y)=1/2$ for $y\in{0,1}$ ...
user avatar
2 votes
1 answer
87 views

Stuck on a step calculating Naive Bayes Classifier,

Using the example at 3Blue1Brown I constructed a table to help me remember Bayes theorem where L=Librarian and S =Shy. I understand that $$P(S,L) = P(S|L)P(L) = P(L|S)P(S) = \frac{4}{210}$$ I am ...
user avatar
  • 461
0 votes
0 answers
11 views

How to use K-fold classifier for comparison of different models

I am learning machine learning and went through a term K-fold cross validation. I also took notes from this site to enhance my understanding. As per the tutorial if it is 3 fold cross validation and ...
user avatar
  • 121
0 votes
0 answers
97 views

How many divergent transitions are too many?

I am running a Bayesian linear mixed effects analysis. Four chains for 3000 iterations. I end up with four divergent transitions. Is this too many or can I proceed? How do I know if it's too many? I'...
user avatar
  • 1,641
0 votes
0 answers
14 views

Naive Bayes for data generation

NB is a classification method which according to Bishop's book is categorized in probabilistic generative methods. As far as I understood you can learn a join distribution from input-output pairs and ...
user avatar
0 votes
0 answers
10 views

Trouble reading bernoulli Naive bayes notation [duplicate]

Here is a mathematical description of the bernoulli naive bayes taken from the book ,Bayesian Reasoning and Machine Learning by David Barber i want to know what does the notation below means ? if ...
user avatar
1 vote
0 answers
15 views

Base rate calculation for customer conversion

Question: What is the base rate of conversion for mobile versus desktop sites? Total no of customers: 590381 Out of 590381, the Total no of customers that were converted: 701 These customers used ...
user avatar
  • 11
5 votes
2 answers
488 views

Intuition for why LDA is a special case of naive Bayes

The naive Bayes classifier assumes the regressors to be mutually independent, while linear discriminant analysis (LDA) allows them to be correlated. James et al. "An Introduction to Statistical ...
user avatar
5 votes
1 answer
237 views

Why is naive Bayes overconfident?

In the fourth edition of "Artificial Intelligence: a modern approach" by Russel and Norvig, they write in section 12.6, regarding the Naive Bayes Model for text classification, the following:...
user avatar
  • 171
0 votes
1 answer
1k views

How can Naive Bayes overfit the data?

I know that Laplace smoothing results in a high bias of Naive Bayes. If the value of the smoothing parameter (alpha) is large, then the probability distribution will be uniform for all the features. ...
user avatar
2 votes
1 answer
142 views

Parameters in Naive Bayes

This is from https://scikit-learn.org/stable/modules/naive_bayes.html In the last line it says and we can use Maximum A Posteriori (MAP) estimation to estimate $P(y)$ and $P(x_i|y)$; the former is ...
user avatar
  • 21
0 votes
0 answers
14 views

Modelling probability of continuous dependent variable from multivariate continuous independent variables

I am trying to create a model that predicts the probability of the size of a continuous dependent variable based on a number of (4) continuous independent variables. My dataset has 67 data ...
user avatar
0 votes
0 answers
18 views

Why use naive bayes instead of computing probability directly [duplicate]

Situation: In the exam question found below, we are tasked with using the naive bayes assumption to find: $$P[K = 1 | a = 1 \land b = 1 \land c = 0]$$ Problem: Although I could solve the exercise, I ...
user avatar
  • 121
0 votes
0 answers
23 views

naive bayes pseudo code and cleaning techniques

so let's say you are a librarian at a local library responsible for organising documents in 3 categories: new, fictions and scientific articles. one day, the library obtained access to some new ...
user avatar
0 votes
0 answers
8 views

How to count p(data) for Naive Bayes in the table below?

I'm trying to learn more about naive bayes + their calculation so I read the paper from Rennie et al, "Tackling the Poor Assumptions of Naive Bayes Text Classifiers". I'm curious about the ...
user avatar
1 vote
1 answer
544 views

Product of two normal distributions (for Bayes Rule) is not product of normal output variables?

When we apply Bayes' rule in machine learning, we want to compute the posterior probability $P(y|X)$ by multiplying two probability distributions (the observed class-conditional likelihood $P(X|y)$ ...
user avatar
0 votes
1 answer
110 views

Logic of Sklearn Bernoulli Naive Bayes Classifier when the the predictors are not even binary?

I know the mathematics behind the Naive Baye's Bernoulli Classifier Algorithm and it is used to calculate the probabilistic results. As we know the Bernoulli Naive Bayes Classifier uses binary ...
user avatar
0 votes
0 answers
28 views

What is the prior probability in a Dynamic Naive Bayes classifier?

For a Hidden Markov process with multiple types of emissions, it is possible to perform current state classification using the Naive Bayes likelihood estimation: $ p(j|b,d) \propto p(b|j) \cdot p(d|j) ...
user avatar
0 votes
0 answers
21 views

why doesn't naive bayes use the empirical distribution for continuous predictor by default?

Many standard implementations of naive bayes assume a gaussian distribution for the likelihood for continuous predictors. why doesn't it use the empirical distribution instead (or some kernal density ...
user avatar
  • 1,220
0 votes
1 answer
47 views

Binary Classification with OpenNLP

I'm trying to apply binary classification with OpenNLP. I could already successfully classify movies by different genres. The data sample has the form: ...
user avatar
  • 3
0 votes
0 answers
16 views

Function to sort a static list of items by recency and frequency

I'm working on a problem which requires me to sort a list of static items for each user. I understand best way to solve this problem would be to come up with a function that captures both the ...
user avatar
  • 109
2 votes
1 answer
48 views

Does it make sense to use Gaussian Naive Bayes for a single feature?

I understand that 'Naive' Bayes refers to the approach where all the features are assumed to be independent. But I want to evaluate the performance of each feature individually before I combine all of ...
user avatar
  • 163
0 votes
0 answers
47 views

Difference between Categorical Naive Bayes classifier and IBCC (independent bayesian classifier combination)

I am implementing an IBCC classifier to predict the probability of a given output class $y$ given some categorical inputs $X$. The paper I am usiing for this purpose is: https://www.oxford-man.ox.ac....
user avatar
  • 51
-1 votes
1 answer
44 views

How to re-write with Bayes' Rule as a function?

I'm a little bit stuck. Say I have a P(A | B ^ C). How could I re-write this as a function with the terms P(B|A ^ C), P(B|C) and P(C|B) and can anyone explain how this was done?
user avatar
  • 1
2 votes
2 answers
168 views

Naive Bayes - having trouble coming up with a case where Laplace smoothing changes the prediction

I'm thinking through the logic of Naive Bayes and encountered a brain teaser. I know that adding smoothing (alpha) to Naive Bayes can help to increase the accuracy of the model, which implies that it ...
user avatar
1 vote
1 answer
347 views

How to choose prior in Laplace Smoothing Naive Bayes?

Please check the image for reference How to choose the prior probability of each feature . Should we use the same prior for every feature or different features use different prior. for example ...
user avatar
0 votes
0 answers
118 views

How should I handle Laplace smoothing in Naive Bayes in this example?

I have a toy dataset on animals, with 4 features and 2 possible classes (mammals vs non-mammals). I have summarized the dataset ...
user avatar
2 votes
1 answer
43 views

On the denominator of Bayes and Naive Bayes

There are many question on the topic but I think the comparison below is harder to find. Let us assume that all variables in this example are binary for the sake of simplicity. The typical academic ...
user avatar
  • 721

1
2 3 4 5
12