Hi, in the last past of this programming assignment, we use regularization for the logistic regression. If I vary the lambda from 1 to 0.00000001, the train accuracy does not change . It stays at 82.203390.
Why does the accuracy not change? What is the intituition? Thanks!
Just to verify your code further:
- If you use lambda = 3, you should get about 80% accuracy.
- If you use lambda = 10, you should get about 74% accuracy.
Given the variance in this data set, even with a very small lambda value, it’s not possible to overfit this training set. Small lambda values aren’t going to do very much.
You have to use a fairly large lambda value before you get into underfitting.
Also since there are only 118 examples in this training set, most of the digits displayed for the accuracy are not significant.
The 82.203390% value represents 97 correct predictions. To change the accuracy percentage, you’ll have to modify the lambda value enough to create at least one more incorrect prediction. The accuracy percentage will only change in increments of 1/118, or about 0.85%
Hi @TMosh , thank you very much for the explanation!
I get the point: if the variance in the data set is very small, it is unlikely to get an overfitting.