(Basic Statistics for Citizen Data Scientist)
Equivalence Testing (TOST)
The objective of a two-sample equivalence test is to determine whether the means of two populations are equivalent based on two independent samples from these populations; here “equivalent” means that the two means differ by a small pre-defined amount. This margin of equivalence is determined by knowledge of the domain under study and represents the tolerance that is acceptable.
A two one-sided t-test (TOST) is used to make this determination. Essentially, TOST reverses the roles of the null and alternative hypotheses in a two-sided t-test.
If θ represents the margin of equivalence, then we test the hypotheses:
H0: μ2 – μ1 ≤ –θ or μ2 – μ1 ≥ θ
H1: –θ < μ2 – μ1 < θ
This is done by conducting two one-sided t-tests, each of which is based on a null-hypothesis that is one of the parts of the above null hypothesis. If the null hypothesis of both tests are rejected then the difference falls within the equivalence interval and you can claim that the two population means are equivalent. The larger p-value of the two t-tests is used as the p-value of the TOST.
Another way of looking at this method is to conduct a two-sided t-test and determine the 1–2α confidence interval I. If the confidence interval I lies completely within the interval (-θ, θ) then we accept that the two means are equivalent.
We can also use two different limits for the margin of equivalence, an upper value θU and a lower value θL. In this case, θU replaces θ in the TOST method described above and θL replaces –θ.
The TOST approach can also be used for a one-sample test (and similarly for a two dependent sample test). In this case, we test the equivalence between the mean of a single population and some hypothetical mean μ0.
H0: μ – μ0 ≤ θL or μ – μ0 ≥ θU
H1: θL < μ – μ0 < θU
This time we conduct two one-sample t-tests. Alternatively, if the 1–2α confidence interval for the two-tailed one-sample t-test lies completely within the interval (θL, θU) then we accept that the population mean and hypothetical mean are equivalent.
Example 1: A company that markets a premium brand of fresh salmon has found a second supplier, but wants to make sure that the level of omega-3 is within 25 mg of their existing suppliers’ for a 100 gram serving. Using the random sample of 12 servings from each supplier as shown on the left side of Figure 1 determine whether the sources are equivalent based on alpha = .05.
The right side of Figure 1 shows the analysis for a two independent sample t-test. Since the 90% confidence interval (-9.17, 23.33) is completely contained in the interval (-25, 25), we conclude that the two sources are equivalent.
Note that if we test the two one-sided null hypotheses directly, we would obtain p-values of .036 and .0013. Since both are less than alpha = .05, we again conclude that the two sources are equivalent (with p-value = .036).
Note too that a two-sided t-test would yield a p-value = .46 and so we can also conclude that there is no significant difference between the two suppliers.
Figure 1 – TOST
Statistics for Beginners in Excel – Equivalence Testing (TOST)
Disclaimer: The information and code presented within this recipe/tutorial is only for educational and coaching purposes for beginners and developers. Anyone can practice and apply the recipe/tutorial presented here, but the reader is taking full responsibility for his/her actions. The author (content curator) of this recipe (code / program) has made every effort to ensure the accuracy of the information was correct at time of publication. The author (content curator) does not assume and hereby disclaims any liability to any party for any loss, damage, or disruption caused by errors or omissions, whether such errors or omissions result from accident, negligence, or any other cause. The information presented here could also be found in public knowledge domains.
Learn by Coding: v-Tutorials on Applied Machine Learning and Data Science for Beginners
Latest end-to-end Learn by Coding Projects (Jupyter Notebooks) in Python and R:
All Notebooks in One Bundle: Data Science Recipes and Examples in Python & R.
End-to-End Python Machine Learning Recipes & Examples.
End-to-End R Machine Learning Recipes & Examples.
Applied Statistics with R for Beginners and Business Professionals
Data Science and Machine Learning Projects in Python: Tabular Data Analytics
Data Science and Machine Learning Projects in R: Tabular Data Analytics
Python Machine Learning & Data Science Recipes: Learn by Coding
R Machine Learning & Data Science Recipes: Learn by Coding
Comparing Different Machine Learning Algorithms in Python for Classification (FREE)
There are 2000+ End-to-End Python & R Notebooks are available to build Professional Portfolio as a Data Scientist and/or Machine Learning Specialist. All Notebooks are only $29.95. We would like to request you to have a look at the website for FREE the end-to-end notebooks, and then decide whether you would like to purchase or not.