Consider, for example, that I demand that every farmer gives me 10 of their best apples from each of the tens of apple orchards that I own. I detest worms in my apples, but know that some will worm their way into some of them in any case.

The farmers know exactly how many of their apples contained worms and they give me a proportion relating the number of spoilt fruit to the number of all apples produced in their orchard. The orchards are of different sizes and are known.

Despite warnings, I find some worms in my treats. How can I know whether the farmers tried to cheat me or this was a sincere mistake on their part?

In other words, how can I know the proportions of worm-eaten apples in my small samples are indeed smaller than the general proportions in their orchards? Note, that I would like a general assessment of fairness of my farmers. That is, I am not looking to single out a farmer and its fruit garden, but instead have a general sense of whether (most of) the farmers are trying to cheat me or not.

My thoughts and questions:

  • Is a paired t-test (or a non-parametric alternative) an appropriate analysis here given that one of the samples is actually the whole population (all of the apples produced in an orchard)?
  • What can the correlation between the proportion of wormy fruit in my sample and the proportion in the corresponding orchard tell me? Should I expect this correlation to be zero if the farmers are fair?
  • Are the sizes of orchards of importance here? Given that my sample is always of fixed size, should I take the sizes of the populations into account somehow?
  • Should I drop the idea of proportions altogether and do something with raw number of apples?

I was trying to find related questions and this one tried to compare proportions. My example is different (or doesn't it matter?), however, because I have population estimate on one hand.

  • $\begingroup$ It does not seem possible to answer your questions with such data: the apples offered you are not random samples; there may be differences among the farms; and you have no controls to compare what you receive to what is typical of those farms. Suppose some test were to declare there is a "significant" difference in the data: what then? It would not be valid to draw any conclusions about cheating, fairness, or even apple quality generally. $\endgroup$
    – whuber
    Oct 9, 2017 at 18:47
  • $\begingroup$ 1) You could simply compare the ratio of normal to worm-infested apples with a $\chi^2$-test for given probabilities, where the given probabilities are the numbers the farmers claim. 2) The proportions are single numbers, what do you mean by correlation between them? $\endgroup$ Oct 9, 2017 at 18:49
  • 2
    $\begingroup$ You are at risk of getting answers that may be invalid for your actual problem because they rely (perhaps only implicitly) on assumptions true for the made-up problem but not true for the real problem. It's almost always better to describe the problem you face rather than attempting to present it abstractly. Another risk is that as answers emerge you may discover some of these inadequacies of the abstraction, compelling you to change the details of the question, which leaves the entire thread in a terrible mess. $\endgroup$
    – whuber
    Oct 9, 2017 at 19:23
  • 1
    $\begingroup$ If I had a nickel for every question on Cross Validated that was phrased as a hypothetical or metaphorical scenario that turned out to be a poor representation of the real problem, I'd be a wealthy man. Why people are so reluctant to describe their real problem, I'll never know. Are they afraid we'll steal their ideas? Or are they so embarrassed about asking a question here that they don't want their real-life colleagues to recognize the scenario? $\endgroup$ Oct 9, 2017 at 20:11
  • 1
    $\begingroup$ @whuber and Kodiologist, you both raised good points. I realize now that this question is more difficult to answer, given that it is a hypothetical. The reason I chose to rephrase the question as a simpler one is that the original problem is well out of my field of expertise. So, by trying to simplify it, I was trying both to communicate it better and grasp the core of it myself. I am aware that this might make the answers less relevant. Thank you for trying to help me despite this! $\endgroup$
    – Fato39
    Nov 1, 2017 at 12:22

1 Answer 1


You have a contingency table comprising 10 rows (1 for each orchard), and 2 columns (contains worms and not contains worms). You know the null probabilities for bad apple in each of the 10 farms, and you are trying to find if the deviation is very large. The answer will be a chi-square test which tests for large deviations.

  • $\begingroup$ Thank you, Sid, for this answer. Would you mind elaborating on why this would be preferable to doing a paired t-test as I suggested? Also, am I right in thinking that a larger table (i.e. a larger number of orchards) would result in a chi-square test with more power? $\endgroup$
    – Fato39
    Oct 9, 2017 at 19:11
  • $\begingroup$ Hi Fato39, please see biology.stackexchange.com/questions/13486/… $\endgroup$
    – Sid
    Oct 9, 2017 at 20:49
  • $\begingroup$ Sid, thank you for providing the link to a helpful answer! I accepted your answer as I tend to think it's correct, but if you cared to elaborate on any other subquestions I posed, please edit it. $\endgroup$
    – Fato39
    Nov 1, 2017 at 12:29

Your Answer

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

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