1
$\begingroup$

I would like to implement a classifier on a dataset which does not have a label. I've written a script which labels each row of the source file by some specific values like "IF H > 45 && T <= 89 THEN label = True".

Does it make sense to do something like this? I mean if I'm able to label the dataset by the script I've wrote, why do I need the classifier? There are any arguments why it makes sense to still use a classifier for it?

$\endgroup$
1
$\begingroup$

If you label it using specific rules which can be encoded easily than it means you know the model and it doesn’t make sense to learn it, you already know it. However there are cases when you want that. One example would be when you want to learn a different form of the classifier. For example to see and gain insights from a fitted logistic regression.

Another common use case is when you want to transfer knowledge from human to models. For example humans are good at recognizing objects in images. You label them manually and fit a classifier to automate this activity

$\endgroup$
1
$\begingroup$

The chicken egg dilemma

What came first: the labeled data or the machine learning model?

  • If you have labeled data, then you can train a machine learning model.

  • If you have a trained machine learning model, then you can label data.

Precision vs. Recall

Suppose you are in case 2 (you have a model). Then how is the precision and recall of your model? Unless both are $100\%$, you might still want to label data.

                       recall
                 100%     |     < 100%
          --------------------------------------
          Your model is   | You can confidently
p   100%  perfect. You    | trust the labels you
r         don't need more | get. But your model 
e         data.           | might miss some.
c         --------------------------------------
i         You get         | You get some 
s  < 100% labels, but you | labels, but you
i         still need to   | still need to
o         confirm that    | confirm that
n         they are correct| they are correct

Most people will be at the lower-right quadrant (precision and recall will be $\lt100\%$). The goal will be to get as close as possible to $100\%$. Therefore, the model will output labels which can be the basis for manual labeling.

Your case

If you can label all rows with some rules and you are creating these rules, then, in fact, you are already manually labeling data. Further, you could use a decision tree later on, to model all your rules in order to deal with new data points that come your way.

$\endgroup$
  • $\begingroup$ What exactly would be the benefit of using a decision tree in that case? Is it just that I dont have to implement the logic because it's covered by the model? $\endgroup$ – Stev Sep 2 '18 at 14:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.