1
$\begingroup$

I have been playing around the NLTK algorithm for some data prediction.

Starting from this gib, I started my understanding process. However, there are some bits that don't make sense.

If I have a set of 100 features, all classified, what's the sense to split them, take 10% and build the training set on that alone? I thought the training set should have included all the list, and accuracy is measured against the new keywords being tested against?

Any hint would be helpful.

$\endgroup$

1 Answer 1

1
$\begingroup$

If you don’t have a classified testing set - which allows to measure a performance score, then it is useful to use part of your training data as a validation set, meaning that you test the performance of your model on it (because you have the true labels/values).

The percentage of the split is arbitrary and depends on the degrees of freedom you have (number of individuals vs number of variables) - 0.1 to 0.25 is a common choice.

$\endgroup$
1
  • $\begingroup$ Hi, I have my trained test set already, and the example n the git calculates the accuracy by splitting the training set in two parts. However, if I change the code to use the full data set (300 words) and later classify the keyword and check its accuracy I always get 100%, which I love but sounds strange because no matter which sentence I test, the accuracy is always that hgh. Any idea? $\endgroup$ Aug 28, 2019 at 6:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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