training set features different from test set feat

2019-09-21 10:57发布

问题:

I have two data set, train data set and test data set and I want to predict on these data sets. My train data set has these features:

 ID, name, age, Time of recruitment, Time fired, status

My test data set has these features:

ID, name, age, Time of recruitment

Now I want to predict “status” for test data set, but number of train data set features are different from test data set. Train data set has the “Time fired” feature while test data set has not it.
What should I do?

回答1:

If a model uses a particular attribute, then it is required in the test set for prediction.

Is 'Time fired' an important/critical attribute for the prediction? If not you could just leave it out in the training data as well. If it is, you'll have to find a way to collect it in the test data as well.