One kind are “natural” pairings, such as spouses, siblings, and especially twins. This type of pairing is often used in medical observational research when it is difficult to construct a true experiment. (PennState, 2017)
But even more common are other types of pairing. A more accurate label for this two-sample test is a test for dependent samples. Samples are dependent when there is a relationship of some kind in play which causes the samples to not be independent.
I like this definition from the Minitab blog:
If the values in one sample affect the values in the other sample, then the samples are dependent.
If the values in one sample reveal no information about those of the other sample, then the samples are independent. (Minitab, n.d.)
Another author states the requirement for a two-sample sample test for independent samples is:
“The two samples are randomly selected in an independent manner from the two target populations.” (McClave, Benson, & Sincich, 2014)
Another way of thinking about dependent vs independent samples: If there is no random process in selecting the second sample, the samples are dependent.
One example of a paired/dependent sample situation is comparing daily sales for two specific restaurants. We randomly pick 12 days from 2016 and get the sales for the two restaurants on those 12 days. Are the two samples independent? [data from (McClave, Benson, & Sincich, 2014)]
The answer is they are not. Although we randomly picked the 12 days, once we get the sales data for restaurant 1 we must get the same 12 days for restaurant 2. The second sample is not random – it is linked to the first sample.
If we mistakenly run the independent samples t-test, we get the following:
The large p-value tells us the sales for the two restaurants are not different.
But, if we correctly run the paired samples t-test, we find a small p-value:
The sales for the two restaurants are different!
Remember there are more types of “paired” samples than just before and after.
P.S. The image below shows the Excel PHStat version of the two tests: