I dont understand how the lecturer solved this problem. The question is:

You are working with a dataset that contains descriptions of toxic and non-toxic substances. The dataset, which consists of 1000 samples from each of the two classes, is described in terms of a class label and a number of attributes. The dataset is sorted so that the 1000 toxic samples come first, followed by the 1000 non-toxic samples. Someone tells you that they have confirmed that, for this data set, the conditional probability that is gained from knowledge about attribute X is not different from the prior class probability. Assuming that they are correct, which of the following statements could be correct and which could not be correct?

  1. All samples have the same value for attribute X.
  2. All toxic samples have the same value for attribute X while each of the non-toxic samples has its own random value for attribute X.

My question is how can either of these answers to this question be correct when the information given is very limited?

The book we use for data mining is Witten and Frank, Data Mining: Practical Machine Learning Tools and Techniques, Morgan Kaufmann, 2011 (3rd ed.).

  • $\begingroup$ I do not have much inspiration for the title. Feel free to update with a more informative one. Is it possible to get a proper link to your lectures? $\endgroup$ – chl Sep 25 '12 at 15:07
  • $\begingroup$ Has the course covered "information theory" by any chance? Entropy, mutual information, etc? $\endgroup$ – Michael McGowan Sep 25 '12 at 16:43
  • $\begingroup$ Chl: The lectures are only accessible to the students of that univ. The course has not yet covered entropy or mutual information. We have studied decision tree, lift charts, ROC curves, Naïve Bayes ,quadratic loss, information loss but only theoritically. I think this question probably is based on what we have studied so far. $\endgroup$ – Jenn Sep 25 '12 at 17:05
  • 1
    $\begingroup$ Jenn, FYI if you address chl by using the @ symbol (like this: @chl), he'll receive a notification that you responded to him. $\endgroup$ – Michael McGowan Sep 25 '12 at 17:11
  • $\begingroup$ Thanks, Jenn. I have deleted your previous comment (for obvious reason of copyright). $\endgroup$ – chl Sep 25 '12 at 19:13

I would not say that the information is very limited because you have 1000 samples from each group (toxic samples and non-toxic samples). The conditional probability can be estimated from the data and compared to the prior unconditional probability. It suggests that the covariate is not useful in gaining knowledge about the classes. Now if all samples had the same value for attribute X wouldn't that mean that the data does not tell you anything about attribute X for predicting the class. The result about the conditional probability could happen for other reasons and (1) need not be true. But it is possible and if it were true it would explain the result.

Now regarding (2) if all toxic values have a particular value x for the attribute and the nontoxic ones could be different X is useful because whenever X differs from x it would have to be from the nontoxic class. When it is x it could be from either class.But it seems that if X=x you would be best off predicting toxic and you should definitely pick nontoxic when it differs from x. Being that this is the case the finding that X does not help in prediction of classes could not be true. So (2) can't happen. There is an underlying assumption that I am making which is that the sample size is so large that you know that when the sample is toxic it is sure (or very highly probably) that X=x. Also you have a good estimate of the probability that X is equals x when it is nontoxic.

For answer 3 (not given in the question but added in the comments) a different distribution is described for X but both classes have the same distribution for X so that is also a possible scenario to explain why X is useless for classification. In (1) both distributions are constant with the same constant while in (3) both distributions are uniform between 1 and 100 half the time and the same constant value the other half of the time.

  • $\begingroup$ Thank you @Michael Chernick . But I still need more explanation for 1). This is because 1) and 2) are just part of the questions. In the 3rd question : Every second example in the data set has the same value for attribute X while the others have a random value between 1 and 100. of which the answer is also True. How can questions 1,2 and 3 all be true when they contradict one another? $\endgroup$ – Jenn Sep 25 '12 at 17:43
  • $\begingroup$ I did not see 3) in your question. From 1) and 2) I am saying 1) is correct and 2) is incorrect. The question suggests that an answer can be correct and the other answer can be incorrect. So i don't see your issue. Scenario 1) could happen and explain the result you were told about the conditional probability but scenario 2) contradicts what you were told and hence has to be incorrect. $\endgroup$ – Michael R. Chernick Sep 25 '12 at 17:54
  • $\begingroup$ There are actually 9 questions for this dataset. In the original question , I showed only 2. My lecturer's solution, he stated that 1) is correct but in the 3)rd question he asked Every second example in the data set has the same value for attribute X while the others have a random value between 1 and 100. of which the answer is also True. If 1) is True and 3) is True that seems to contradict one another. $\endgroup$ – Jenn Sep 25 '12 at 19:02
  • $\begingroup$ If I understand question 3 correctly it is just a second scenario different from 1) where the covariate X would not be useful in discriminating between toxic and non toxic samples. That is because both sets have the same distribution of values for X. Half of the values are the same fixed value and the other half are uniformly distributed between 1 and 100. If the distribution of X is the same for both classes X is not useful in discriminating between the toxic and the non-toxic classes. So 3) is correct. This is just a second way the two distributions can be identical. $\endgroup$ – Michael R. Chernick Sep 25 '12 at 20:05
  • $\begingroup$ In case 1 both distributions were constant with the same constant. In three the distributions are the same in a more complicated way. But the point is that both classes have the same distribution. It does not matter that the scenarios are different. For the answer to be correct it only had to be a POSSIBLE WAY for X to be useless and any way that leads to the two class conditional distributions to be identical render X useless! $\endgroup$ – Michael R. Chernick Sep 25 '12 at 20:08

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.