Questions tagged [logistic-regression]

For questions related to Logistic regression in the context of machine learning and AI. Logistic regression is a statistical classification model used for making categorical predictions.

Filter by
Sorted by
Tagged with
1 vote
2 answers
39 views

Are there any toy classification problems that can't be solved with logistic regression, but can be solved with a NN with exactly one hidden node?

Basically, I'm wondering if there are any small and simple problems that are: complex enough to be unsolvable with a standard neural network without any hidden layer (ie. input -> output) simple ...
  • 11
0 votes
0 answers
25 views

Relationship between TD control algorithm (SARSA) and logistic regression in two-armed bandit task

I have been looking for a way to model behavioral data (from rodents) in a nonstationary 2-armed bandit task. In this task the rodent can nose poke either on a left or a right port, and it will get a ...
0 votes
0 answers
25 views

Normal equations for linear decision boundary

For solving linear regression, we have gradient descent and the normal equations, with no iterations. In logistic regression, however, we have gradient descent but no known closed form solution. This ...
1 vote
0 answers
12 views

Is the loss calculation step in Logistic Regression even needed?

I was reading about Logistic Regression and trying to implement the model from scratch. Maybe I am wrong, but I have noticed that the loss calculation step is meaningless in training a Logistic ...
  • 133
1 vote
0 answers
35 views

Data Imbalance in Contextual Bandit with Thompson Sampling

I'm working with the Online Logistic Regression Algorithm (Algorithm 3) of Chapelle and Li in their paper, "An Empirical Evaluation of Thompson Sampling" (https://papers.nips.cc/paper/2011/...
  • 11
1 vote
1 answer
36 views

ML algorithm suggestion for databases that change a lot with time after model training

I have a classification problem and I'm using a logistic regression (I tested it among other models and this one was the best). I look for information from game sites and test if a user has the ...
3 votes
1 answer
84 views

Why does my regression-NN completely fail to predict some points?

I would like to train a NN in order to approximate an unknown function $y = f(x_1,x_2)$. I have a lot of measurements $y = [y_1,\dots,y_K]$ (with K that could be in the range of 10-100 thousands) ...
  • 31
1 vote
0 answers
13 views

How does the distribution of the parameters change in logistic regression?

I have my own data to train a logistic regression model (for a multi-class classification task), and I want to know how the distribution of weight parameters changes after each update with gradient ...
2 votes
2 answers
204 views

Does it make sense for a logistic regression model to perform better than a neural network on the Iris data set?

Per a review post, a simple Logistic Regression model on the Iris data set gets about 97% test accuracy on iris dataset whereas a neural network gets just 94%. The neural network model used in Keras ...
  • 211
1 vote
0 answers
23 views

Is it possible to compute the logical AND and OR with logistic regression?

It's easy to build a perceptron that can compute the logical AND and OR functions of its binary inputs. Logistic regression could be used as a binary classifier. $$z^{(i)} = w^T x^{(i)} + b$$ $$\hat{y}...
  • 211
1 vote
0 answers
54 views

Is the main difference between the logistic regression and the perceptron the activation function they use?

I went through a Stats StackExchange's post about the difference between logistic regression and perceptron, which is too long to get the key point. I'd like to consider the question in terms of the ...
  • 211
2 votes
1 answer
461 views

How to get more accuracy of the logistic regression model?

I am working on a Baby Crying Detection model using logistic regression. Out of $581$ audios, $222$ are of a baby crying. Each audio is of $5$ seconds. what I have done is convert each audio into ...
0 votes
0 answers
64 views

How do we interpret the images of weights in logistic regression

The following images are a) The weights of a logistic regression model trained on MNIST. b) The sign of the weights of a logistic regression How do these images represent the weights? Would be ...
  • 159
3 votes
1 answer
86 views

What is meant by "the number of examples is reduced", and why is this the case?

I am currently studying the paper Learning and Evaluating Classifiers under Sample Selection Bias by Bianca Zadrozny. In section 3.2. Logistic Regression, the author says the following: 3.2. Logistic ...
1 vote
1 answer
64 views

Does the image is logistic regression or SVM, and why? [closed]

Does the image is logistic regression or SVM, and why?
0 votes
0 answers
91 views

How to frame this problem using RL?

How should this problem be framed in the domain of RL for preventing users from exceeding their bank account balance and being overdrawn? For example, a user has 1000 in an account, and proceeds to ...
  • 325
1 vote
1 answer
160 views

Back propagation approach to logistic regression: why is cost diverging but accuracy increasing?

Background I have tried to fit a logistic regression model - written using a forward / back propagation approach (as part of Andrew Ng's deep learning course) - to a very non-linear data set (see ...
0 votes
1 answer
226 views

Hyper-plane in logistic regression vs linear regression for same number of features

Geometric interpretation of Logistic Regression and Linear regression is considered here. I was going through Logistic regression and Linear regression. In the optimization equation of both following ...
  • 1
1 vote
0 answers
40 views

Given the same features, do logistic regression and neural networks produce the same output?

I have a binary classification problem. I have variables (features) var1, var2, var3, ..., var14. Using these variables (aka features) in a logistic regression, I get their weights. If I use the same ...
  • 111
1 vote
1 answer
71 views

How could logistic loss be used as loss function for an ANN?

Normally, in practice, people use those loss functions with minima, e.g. $L_1$ mean absolute loss, $L_2$ mean squared error, etc. All those come with a minimum to optimize to. However, there's ...
  • 1,283
2 votes
1 answer
190 views

Why is the hypothesis function $h_{\theta}(x)$ equivalent to $E[y | x; \theta]$ in generalised linear models?

Reading through the CS229 lecture notes on generalised linear models, I came across the idea that a linear regression problem can be modelled as a Gaussian distribution, which is a form of the ...
  • 1,251
2 votes
1 answer
194 views

How does the weight update formula for logistic regression work?

I am trying to use Logistic Regression to make a spam filter, but I am having trouble understanding the weight update part. I have processed my email dataset, and I have an attribute vector of the top ...
  • 31
2 votes
0 answers
49 views

Is logistic regression used for unconstrained or constrained optimisation problems?

Is logistic regression used for unconstrained or constrained optimization problems, and why?
  • 21
2 votes
1 answer
76 views

Is it compulsary to normalize the dataset if doing so can negatively impact a Binary Logistic regression performance?

I am using raw data set with 4 feature variables (Total Cholesterol, Systolic Blood Pressure, Diastolic Blood Pressure, and Cigraeette count) to do a Binominal Classification (find stroke likelihood) ...
  • 51
3 votes
3 answers
2k views

Why not use the MSE instead of the current logistic regression?

When watching the machine learning course on Coursera by Andrew Ng, in the logistic regression week, the cost function was a bit more complex than the one for linear regression, but definitely not ...
user avatar
1 vote
1 answer
99 views

Is there a Logistic Regression classifier that can perfectly classify the given data in this problem?

I have the following problem. A bank wants to decide whether a customer can be given a loan, based on two features related to (i) the monthly salary of the customer, and (ii) his/her account balance. ...
  • 145
2 votes
0 answers
71 views

How to define cost function for custom nonlinear functions?

For logistic regression, the Cost function is defined as: \begin{equation} Cost(h_{\theta}(x)-y) = -ylog(h_{\theta}(x))-(1-y)log(1-h_{\theta}(x)) \end{equation} I now have a nonlinear function \begin{...
  • 51
3 votes
0 answers
1k views

What is the right formula for weight update rule in Logistic Regression using stochastic gradient descent

Apologies for the lengthy title. My question is about the weight update rule for logistic regression using stochastic gradient descent. I have just started experimenting on Logistic Regression. I ...
  • 51
1 vote
1 answer
97 views

How many parameter would there be in a logistic regression model used to classify reviews into "good" or "bad"?

Suppose we want to classify a review as good ($1$) or bad ($0$). We have a training data set of $10,000$ reviews. Also, suppose we have a vocabulary of $100,000$ words $w_1, \dots, w_{100,000}$. So ...
1 vote
1 answer
68 views

Are these steps to get a final linear regression model correct?

I am new to machine learning. I know Logistic Regression (LR) is a supervised learning technique. Therefore, we need training data to train the model. I tried to understand the basic steps to get the ...
  • 111
4 votes
2 answers
570 views

What are the differences between softmax regression and logistic regression (other than when the number of classes is 2)?

I read about softmax from this article. Apparently, these 2 are similar, except that the probability of all classes in softmax adds to 1. According to their last paragraph for ...
user avatar
5 votes
1 answer
873 views

Is logistic regression more free from the conditional independence assumption than naive Bayes?

To my understanding, logistic regression is an extension of naive Bayes. Suppose $X = \{x_1, x_2, \dots, x_N \}$ and $Y = \{0, 1\}$, each $x_i$ is i.i.d and $P(x_i \mid Y=y_k) \sim \mathcal{N}(\mu, \...