Logistic Regression Flashcards
a supervised, classification learning algorithm where features can be discrete or continuous or a mix of both.
Logistic Regression
Used to map the output of a linear regression model to a 0-1 range. It will always return a value from 0-1.
Sigmoid Function
What is the Sigmoid Function formula?
1/1+e^-x
What is the pre-sigmoid value Logistic Regression Model?
1/1+e^ -(t1x1+t2x2+…tdxd+t0)
shows statistics of the prediction
Confusion Matrix
predicted and classified as positive
True Positive
predicted and classified as negative
True Negative
predicted as negative but it is positive
False Negative
predicted as positive but it is negative
False Positive
number of correctly classified instances over all instances
Accuracy
What is the formula of Accuracy?
TP+TN/TP+FP+TN+FN
out of all instances that are predicted as positive, how many are really positive?
Precision
What is the formula for precision?
TP/TP+FP
out of all positive instances, how many are predicted as positive?
Recall
What is the formula for Recall?
TP/TP+FN
harmonic mean of precision and recall
F1-Score
What is the formula of F1-Score?
2 x ((precision x recall)/(precision + recall))
It converts scores into a probabilistic representation that totals to 1. It can handle negative values.
Softmax Function
label for a single instance is converted to what?
one-hot encoded vector
It shows the prediction results across the feature space. It is determined by the value of feature x_i, where z=0.
Decision Boundary
This is used for more than 2 classes
Multinomial Logistic Regression