Question

I know that:

  1. unsupervised learning is that of trying to find hidden structure in unlabeled data,otherwise ,we call it supervised learning.
  2. regression is also a type of classification ,except that its output is infinite number of numeric numbers.
  3. I also know that classification is a type of supervised learning.

But what make me confused is:

  1. linear regression(line fitting) is a type of regression? if so , why its data is unlabeled?For example, its sample data is just a quantity of coordinates like (1,2),(2,3),(1,4)?
  2. logistic regression(classification) is a type of regression ?if so ,why its output is just norminal(value,true of false ,0 or 1)?

Anyone can help me figure out this?

Was it helpful?

Solution

1) Linear Regression is Supervised because the data you have include both the input and the output (so to say). So, for instance, if you have a dataset for, say, car sales at a dealership. You have, for each car, the make, model, price, color, discount etc. but you also have the number of sales for each car. If this task was unsupervised, you would have a dataset that included, maybe, just the make, model, price, color etc. (not the actual number of sales) and the best you could do is cluster the data. The example isn't perfect but aims to get across the big picture. A good question to ask yourself when deciding whether a method is supervised or not is to ask "Do I have a way of adjudging the quality of an input?". If you have Linear Regression data, you most certainly can. You just evaluate the value of the function (in this case, the line) for the input data to estimate the output. Not so in the other case.

2) Logistic Regression isn't actually a regression. The name is misleading and does indeed lead to much confusion. It is usually only used for binary prediction which makes it perfect for classification tasks but nothing else.

OTHER TIPS

Linear regression is supervised. You start with a dataset with a known dependent variable (label), train your model, then apply it later. You are trying to predict a real number, like the price of a house.

Logistic regression is also supervised. It's more of a classifier than a regression technique, despite it's name. You are trying to predict the odds ratio of class membership, like the odds of someone dying.

Examples of unsupervised learning include clustering and association analysis.

  • Supervised Learning The computer is presented with inputs (independent variables) and associated labels indicating the class of the observation (dependent variable) The computer attempts to learn the rule that maps inputs to each class New data is classified based on the rule learned by the computer
  • Unsupervised Learning The computer is presented only with inputs (independent variables) The computer attempts to classify things based on similarity/dissimilarity

Hope this clears, Cheers

You may consider this interpretation.

  1. Linear regression (line fitting) is a type of regression? If so, why its data is unlabeled? For example, its sample data is just a quantity of coordinates like (1, 2), (2, 3), (1, 4)?

     x: 1 2 1 is data

     y: 2 3 4 is label

  1. Logistic regression (classification) is a type of regression? If so, why its output is just nominal (value, true of false, 0 or 1)?

     Value: data

     True/False: label

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top