Two Sample T-test – Advanced

Theorem 1: Let  and ȳ be the sample means of two sets of data of size nx and ny respectively. If x and y are normal, or nx and ny are sufficiently large for the Central Limit Theorem to hold, and x and y have the same variance, then the random variable


has distribution T(nx + ny – 2) where


Proof: Let σ be the common standard deviation of x and y. Then  – ȳ has a normal distribution with mean µx – µy and standard deviation


Defining z as follows, we know that z has distribution N(0, 1).


We also know that (n - 1) s_x^2/\sigma^2 has distribution χ2(n– 1) and (n - 1) s_y^2/\sigma^2 has distribution χ2(n– 1), and so

has distribution χ2(n+ n– 2).

Defining t = z\sqrt{m}/u, where m = n+ n– 2, it follows by Property A of Basic Concepts of t Distribution that t has distribution T(m).

where s is defined as in the statement of the theorem.

5 Responses to Two Sample T-test – Advanced

    • Charles says:

      Thank you for catching this error. I have now corrected the mistake.
      I appreciate your helping to make the website more accurate and easy to follow.

  1. badaoui says:

    thank you very much sir for this informations.

  2. Kuldeep Singh says:

    Hi Charls,

    Can u guide me : On interpreting the p value score and result for both hypothesis and that too for same case
    Way1 : H0 = there is no change in awareness level of TG
    Ha = there is significant change in awareness level of TG

    Way2 : H0 = Awareness level has increased among TG post campaign
    Ha = There is no change in awareness level How 2 Null hypothesis for same case

    Can u plz suggest how two different hypothesis for same case can make change in result and interpretation. Please suggest

    • Charles says:

      It sounds like Way1 will require a two-tailed test (in Ha, awareness can increase or decrease), while Way2 requires a one-tailed test (you seem to be ruling out the case where aware decreases).

Leave a Reply

Your email address will not be published. Required fields are marked *