# Two-Sample t-Test (2023)

## What is the two-sample t-test?

The two-sample t-test (also known as the independent samples t-test) is a method used to test whether the unknown population means of two groups are equal or not.

## Is this the same as an A/B test?

Yes, a two-sample t-test is used to analyze the results from A/B tests.

## When can I use the test?

You can use the test when your data values are independent, are randomly sampled from two normal populations and the two independent groups have equal variances.

## What if I have more than two groups?

Use a multiple comparison method. Analysis of variance (ANOVA) is one such method. Other multiple comparison methods include the Tukey-Kramer test of all pairwise differences, analysis of means (ANOM) to compare group means to the overall mean or Dunnett’s test to compare each group mean to a control mean.

## What if the variances for my two groups are not equal?

You can still use the two-sample t-test. You use a different estimate of the standard deviation.

## What if my data isn’t nearly normally distributed?

If your sample sizes are very small, you might not be able to test for normality. You might need to rely on your understanding of the data. When you cannot safely assume normality, you can perform a nonparametric test that doesn’t assume normality.

## Using the two-sample t-test

The sections below discuss what is needed to perform the test, checking our data, how to perform the test and statistical details.

### What do we need?

For the two-sample t-test, we need two variables. One variable defines the two groups. The second variable is the measurement of interest.

We also have an idea, or hypothesis, that the means of the underlying populations for the two groups are different. Here are a couple of examples:

• We have students who speak English as their first language and students who do not. All students take a reading test. Our two groups are the native English speakers and the non-native speakers. Our measurements are the test scores. Our idea is that the mean test scores for the underlying populations of native and non-native English speakers are not the same. We want to know if the mean score for the population of native English speakers is different from the people who learned English as a second language.
• We measure the grams of protein in two different brands of energy bars. Our two groups are the two brands. Our measurement is the grams of protein for each energy bar. Our idea is that the mean grams of protein for the underlying populations for the two brands may be different. We want to know if we have evidence that the mean grams of protein for the two brands of energy bars is different or not.

#### Two-sample t-test assumptions

To conduct a valid test:

• Data values must be independent. Measurements for one observation do not affect measurements for any other observation.
• Data in each group must be obtained via a random sample from the population.
• Data in each group are normally distributed.
• Data values are continuous.
• The variances for the two independent groups are equal.

For very small groups of data, it can be hard to test these requirements. Below, we'll discuss how to check the requirements using software and what to do when a requirement isn’t met.

## Two-sample t-test example

One way to measure a person’s fitness is to measure their body fat percentage. Average body fat percentages vary by age, but according to some guidelines, the normal range for men is 15-20% body fat, and the normal range for women is 20-25% body fat.

Our sample data is from a group of men and women who did workouts at a gym three times a week for a year. Then, their trainer measured the body fat. The table below shows the data.

#### Table 1: Body fat percentage data grouped by gender

 Group Body Fat Percentages Men 13.3 6.0 20.0 8.0 14.0 19.0 18.0 25.0 16.0 24.0 15.0 1.0 15.0 Women 22.0 16.0 21.7 21.0 30.0 26.0 12.0 23.2 28.0 23.0

You can clearly see some overlap in the body fat measurements for the men and women in our sample, but also some differences. Just by looking at the data, it's hard to draw any solid conclusions about whether the underlying populations of men and women at the gym have the same mean body fat. That is the value of statistical tests– they provide a common, statistically valid way to make decisions, so that everyone makes the same decision on the same set of data values.

### Checking the data

Let’s start by answering: Is the two-sample t-test an appropriate method to evaluate the difference in body fat between men and women?

(Video) Two-sample t test for difference of means | AP Statistics | Khan Academy

• The data values are independent. The body fat for any one person does not depend on the body fat for another person.
• We assume the people measured represent a simple random sample from the population of members of the gym.
• We assume the data are normally distributed, and we can check this assumption.
• The data values are body fat measurements. The measurements are continuous.
• We assume the variances for men and women are equal, and we can check this assumption.

Before jumping into analysis, we should always take a quick look at the data. The figure below shows histograms and summary statistics for the men and women.

Figure 1: Histogram and summary statistics for the body fat data

The two histograms are on the same scale. From a quick look, we can see that there are no very unusual points, or outliers. The data look roughly bell-shaped, so our initial idea of a normal distribution seems reasonable.

Examining the summary statistics, we see that the standard deviations are similar. This supports the idea of equal variances. We can also check this using a test for variances.

Based on these observations, the two-sample t-test appears to be an appropriate method to test for a difference in means.

### How to perform the two-sample t-test

For each group, we need the average, standard deviation and sample size. These are shown in the table below.

#### Table 2: Average, standard deviation and sample size statistics grouped by gender

 Group Sample Size (n) Average (X-bar) Standard deviation (s) Women 10 22.29 5.32 Men 13 14.95 6.84

Without doing any testing, we can see that the averages for men and women in our samples are not the same. But how different are they? Are the averages “close enough” for us to conclude that mean body fat is the same for the larger population of men and women at the gym? Or are the averages too different for us to make this conclusion?

We'll further explain the principles underlying the two sample t-test in the statistical details section below, but let's first proceed through the steps from beginning to end. We start by calculating our test statistic. This calculation begins with finding the difference between the two averages:

$22.29 - 14.95 = 7.34$

This difference in our samples estimates the difference between the population means for the two groups.

Next, we calculate the pooled standard deviation. This builds a combined estimate of the overall standard deviation. The estimate adjusts for different group sizes. First, we calculate the pooled variance:

$s_p^2 = \frac{((n_1 - 1)s_1^2) + ((n_2 - 1)s_2^2)} {n_1 + n_2 - 2}$

$s_p^2 = \frac{((10 - 1)5.32^2) + ((13 - 1)6.84^2)}{(10 + 13 - 2)}$

$= \frac{(9\times28.30) + (12\times46.82)}{21}$

$= \frac{(254.7 + 561.85)}{21}$

$=\frac{816.55}{21} = 38.88$

Next, we take the square root of the pooled variance to get the pooled standard deviation. This is:

(Video) two sample t test by hand

$\sqrt{38.88} = 6.24$

We now have all the pieces for our test statistic. We have the difference of the averages, the pooled standard deviation and the sample sizes. We calculate our test statistic as follows:

$t = \frac{\text{difference of group averages}}{\text{standard error of difference}} = \frac{7.34}{(6.24\times \sqrt{(1/10 + 1/13)})} = \frac{7.34}{2.62} = 2.80$

To evaluate the difference between the means in order to make a decision about our gym programs, we compare the test statistic to a theoretical value from the t-distribution. This activity involves four steps:

1. We decide on the risk we are willing to take for declaring a significant difference. For the body fat data, we decide that we are willing to take a 5% risk of saying that the unknown population means for men and women are not equal when they really are. In statistics-speak, the significance level, denoted by α, is set to 0.05. It is a good practice to make this decision before collecting the data and before calculating test statistics.
2. We calculate a test statistic. Our test statistic is 2.80.
3. We find the theoretical value from the t-distribution based on our null hypothesis which states that the means for men and women are equal. Most statistics books have look-up tables for the t-distribution. You can also find tables online. The most likely situation is that you will use software and will not use printed tables.

To find this value, we need the significance level (α = 0.05) and the degrees of freedom. The degrees of freedom (df) are based on the sample sizes of the two groups. For the body fat data, this is:

$df = n_1 + n_2 - 2 = 10 + 13 - 2 = 21$

The t value with α = 0.05 and 21 degrees of freedom is 2.080.

4. We compare the value of our statistic (2.80) to the t value. Since 2.80 > 2.080, we reject the null hypothesis that the mean body fat for men and women are equal, and conclude that we have evidence body fat in the population is different between men and women.

### Statistical details

Let’s look at the body fat data and the two-sample t-test using statistical terms.

Our null hypothesis is that the underlying population means are the same. The null hypothesis is written as:

$H_o: \mathrm{\mu_1} =\mathrm{\mu_2}$

The alternative hypothesis is that the means are not equal. This is written as:

$H_o: \mathrm{\mu_1} \neq \mathrm{\mu_2}$

We calculate the average for each group, and then calculate the difference between the two averages. This is written as:

$\overline{x_1} -\overline{x_2}$

We calculate the pooled standard deviation. This assumes that the underlying population variances are equal. The pooled variance formula is written as:

$s_p^2 = \frac{((n_1 - 1)s_1^2) + ((n_2 - 1)s_2^2)} {n_1 + n_2 - 2}$

The formula shows the sample size for the first group as n1 and the second group as n2. The standard deviations for the two groups are s1 and s2. This estimate allows the two groups to have different numbers of observations. The pooled standard deviation is the square root of the variance and is written as sp.

What if your sample sizes for the two groups are the same? In this situation, the pooled estimate of variance is simply the average of the variances for the two groups:

$s_p^2 = \frac{(s_1^2 + s_2^2)}{2}$

The test statistic is calculated as:

$t = \frac{(\overline{x_1} -\overline{x_2})}{s_p\sqrt{1/n_1 + 1/n_2}}$

The numerator of the test statistic is the difference between the two group averages. It estimates the difference between the two unknown population means. The denominator is an estimate of the standard error of the difference between the two unknown population means.

Technical Detail: For a single mean, the standard error is $s/\sqrt{n}$. The formula above extends this idea to two groups that use a pooled estimate for s (standard deviation), and that can have different group sizes.

We then compare the test statistic to a t value with our chosen alpha value and the degrees of freedom for our data. Using the body fat data as an example, we setα = 0.05. The degrees of freedom (df) are based on the group sizes and are calculated as:

$df = n_1 + n_2 - 2 = 10 + 13 - 2 = 21$

The formula shows the sample size for the first group as n1 and the second group as n2. Statisticians write the t value with α = 0.05 and 21 degrees of freedom as:

$t_{0.05,21}$

The t value with α= 0.05 and 21 degrees of freedom is 2.080. There are two possible results from our comparison:

• The test statistic is lower than the t value. You fail to reject the hypothesis of equal means. You conclude that the data support the assumption that the men and women have the same average body fat.
• The test statistic is higher than the t value. You reject the hypothesis of equal means. You do not conclude that men and women have the same average body fat.
(Video) Two Sample t-test for Independent Groups | Statistics Tutorial #23| MarinStatsLectures

### t-Test with unequal variances

When the variances for the two groups are not equal, we cannot use the pooled estimate of standard deviation. Instead, we take the standard error for each group separately. The test statistic is:

$t = \frac{ (\overline{x_1} -\overline{x_2})}{\sqrt{s_1^2/n_1 + s_2^2/n_2}}$

The numerator of the test statistic is the same. It is the difference between the averages of the two groups. The denominator is an estimate of the overall standard error of the difference between means. It is based on the separate standard error for each group.

The degrees of freedom calculation for the t value is more complex with unequal variances than equal variances and is usually left up to statistical software packages. The key point to remember is that if you cannot use the pooled estimate of standard deviation, then you cannot use the simple formula for the degrees of freedom.

### Testing for normality

The normality assumption is more importantwhen the two groups have small sample sizes than for larger sample sizes.

Normal distributions are symmetric, which means they are “even” on both sides of the center. Normal distributions do not have extreme values, or outliers. You can check these two features of a normal distribution with graphs. Earlier, we decided that the body fat data was “close enough” to normal to go ahead with the assumption of normality. The figure below shows a normal quantile plot for men and women, and supports our decision.

Figure 2: Normal quantile plot of the body fat measurements for men and women

You can also perform a formal test for normality using software. The figure above shows results of testing for normality with JMP software. We test each group separately. Both the test for men and the test for women show that we cannot reject the hypothesis of a normal distribution. We can go ahead with the assumption that the body fat data for men and for women are normally distributed.

### Testing for unequal variances

Testing for unequal variances is complex. We won’t show the calculations in detail, but will show the results from JMP software. The figure below shows results of a test for unequal variances for the body fat data.

Figure 3: Test for unequal variances for the body fat data

Without diving into details of the different types of tests for unequal variances, we will use the F test. Before testing, we decide to accept a 10% risk of concluding the variances are equal when they are not. This means we have set α = 0.10.

(Video) Student's t-test

Like most statistical software, JMP shows the p-value for a test. This is the likelihood of finding a more extreme value for the test statistic than the one observed. It’s difficult to calculate by hand. For the figure above, with the F test statistic of 1.654, the p-value is 0.4561. This is larger than our α value: 0.4561 > 0.10. We fail to reject the hypothesis of equal variances. In practical terms, we can go ahead with the two-sample t-test with the assumption of equal variances for the two groups.

### Understanding p-values

Using a visual, you can check to see if your test statistic is a more extreme value in the distribution.The figure below shows a t-distribution with 21 degrees of freedom.

Figure 4: t-distribution with 21 degrees of freedom and α = .05

Since our test is two-sided and we have set α = .05, the figure shows that the value of 2.080 “cuts off” 2.5% of the data in each of the two tails. Only 5% of the data overall is further out in the tails than 2.080. Because our test statistic of 2.80 is beyond the cut-off point, we reject the null hypothesis of equal means.

### Putting it all together with software

The figure below shows results for the two-sample t-test for the body fat data from JMP software.

Figure 5: Results for the two-sample t-test from JMP software

The results for the two-sample t-test that assumes equal variances are the same as our calculations earlier. The test statistic is 2.79996. The software shows results for a two-sided test and for one-sided tests. The two-sided test is what we want (Prob > |t|). Our null hypothesis is that the mean body fat for men and women is equal. Our alternative hypothesis is that the mean body fat is not equal. The one-sided tests are for one-sided alternative hypotheses – for example, for a null hypothesis that mean body fat for men is less than that for women.

We can reject the hypothesis of equal mean body fat for the two groups and conclude that we have evidence body fat differs in the population between men and women. The software shows a p-value of 0.0107. We decided on a 5% risk of concluding the mean body fat for men and women are different, when they are not. It is important to make this decision before doing the statistical test.

The figure also shows the results for the t-test that does not assume equal variances. This test does not use the pooled estimate of the standard deviation. As was mentioned above, this test also has a complex formula for degrees of freedom. You can see that the degrees of freedom are 20.9888. The software shows a p-value of 0.0086. Again, with our decision of a 5% risk, we can reject the null hypothesis of equal mean body fat for men and women.

## Other topics

### What if I have more than two groups?

If you have more than two independent groups, you cannot use the two-sample t-test. You should use a multiple comparisonmethod. ANOVA, or analysis of variance, is one such method. Other multiple comparison methods include the Tukey-Kramer test of all pairwise differences, analysis of means (ANOM) to compare group means to the overall mean or Dunnett’s test to compare each group mean to a control mean.

### What if my data are not from normal distributions?

If your sample size is very small, it might be hard to test for normality. In this situation, you might need to use your understanding of the measurements. For example, for the body fat data, the trainer knows that the underlying distribution of body fat is normally distributed. Even for a very small sample, the trainer would likely go ahead with the t-test and assume normality.

What if you know the underlying measurements are not normally distributed? Or what if your sample size is large and the test for normality is rejected? In this situation, you can use nonparametric analyses. These types of analyses do not depend on an assumption that the data values are from a specific distribution. For the two-sample t­-test, the Wilcoxon rank sum test is a nonparametric test that could be used.

(Video) Independent Samples t-Test

## FAQs

### How do you solve a two-sample t-test? ›

The test statistic for a two-sample independent t-test is calculated by taking the difference in the two sample means and dividing by either the pooled or unpooled estimated standard error. The estimated standard error is an aggregate measure of the amount of variation in both groups.

What does a 2-sample t-test tell you? ›

The two-sample t-test (Snedecor and Cochran, 1989) is used to determine if two population means are equal. A common application is to test if a new process or treatment is superior to a current process or treatment.

How many samples are best when dealing with t-test? ›

The parametric test called t-test is useful for testing those samples whose size is less than 30. The reason behind this is that if the size of the sample is more than 30, then the distribution of the t-test and the normal distribution will not be distinguishable.

What are the limitations of a two-sample t-test? ›

Just because the t-test can be used on very small samples, it does not justify the use of very small samples unless larger sample sizes are impossible. The t-test should also not be used for multiple comparisons - carrying out dozens (or hundreds) of t-tests means that Type I errors are inevitable.

What is the null hypothesis for a 2 sample t test? ›

Two-Sample t Test

The null hypothesis for this test is that the groups have equal means or that there is no significant difference between the average scores of the two groups in the population.

What is the p-value in a 2 sample t test? ›

It produces a “p-value”, which can be used to decide whether there is evidence of a difference between the two population means. The p-value is the probability that the difference between the sample means is at least as large as what has been observed, under the assumption that the population means are equal.

How do you interpret two tailed t-test results? ›

A two-tailed test will test both if the mean is significantly greater than x and if the mean significantly less than x. The mean is considered significantly different from x if the test statistic is in the top 2.5% or bottom 2.5% of its probability distribution, resulting in a p-value less than 0.05.

How do you analyze t-test results? ›

Interpreting the results isn't very complicated. All you have to do is compare the p-value to an alpha significance level. If the value turns out to be smaller than the alpha level, then you can safely reject the hypothesis. In this scenario, since the alternative hypothesis will be true, the data will be significant.

Can you compare two t-test results? ›

You can compare your calculated t value against the values in a critical value chart (e.g., Student's t table) to determine whether your t value is greater than what would be expected by chance. If so, you can reject the null hypothesis and conclude that the two groups are in fact different.

What is the minimum samples for t-test? ›

There is no minimum sample size required to perform a t-test. In fact, the first t-test ever performed only used a sample size of four. However, if the assumptions of a t-test are not met then the results could be unreliable.

### What is the rule of thumb for t-test? ›

A useful rule of thumb is that if the t statistic is larger in absolute value than 2, reject the null hypothesis; otherwise, accept it. This would apply when n is larger than about 40, using 2 as an approximation to the t value of 1.960. It is thus easy to scan a column of t statistics and tell which are significant.

How many samples should I test? ›

The minimum sample size is 100

Most statisticians agree that the minimum sample size to get any kind of meaningful result is 100. If your population is less than 100 then you really need to survey all of them.

What is a weakness of the t-test? ›

1) The main disadvantage of t-test is it does not give accurate results on large datasets (n >30 samples). If you have larger sample sizes go for Z-test. 2) The sample sizes uses for comparing the means has to be approximately the same.

What is the problem with t-test? ›

The problem is that the test for Normality is dependent on the sample size. With a small sample a non-significant result does not mean that the data come from a Normal distribution.

What are limitations of t-tests? ›

Limitations of T-testing and When Not to Use a T-test

If there are more than two groups being compared, a t-test will undermine the actual error. Ensure that the data in the one sample is at least symmetric. Also, make sure that outliers being present do not distort the results.

How do you know if null hypothesis is rejected in t-test? ›

If the absolute value of the t-value is greater than the critical value, you reject the null hypothesis. If the absolute value of the t-value is less than the critical value, you fail to reject the null hypothesis.

What is the difference between a paired t-test and a 2 sample t-test? ›

Two-sample t-test is used when the data of two samples are statistically independent, while the paired t-test is used when data is in the form of matched pairs.

Do you get p-value from t-test? ›

Another way to find the p-value for a given t statistic is to use the t distribution table. Using the table, look up the row that has degrees of freedom (DF) = 13, then find the values that 1.441 lies between. It turns out to be 1.35 and 1.771.

How do you find the p-value for a two sample t-test in Excel? ›

2. How to find a p-value using the T. TEST function
2. Gather the number of tails and the type of t-test you want to perform.
3. Use the formula =T. TEST(array 1, array 2, tails, type.)
Oct 8, 2021

What is a good t-test score? ›

The critical value that most statisticians choose is ⍺ = 0.05. This 0.05 means that, if we run the experiment 100 times, 5% of the times we will be able to reject the null hypothesis and 95% we will not. Also, in some cases, statisticians choose ⍺ = 0.01.

### What is the critical value for a two tailed t-test? ›

But if it is two tailed test then the critical values are -1.96 and 1.96. of the calculated degrees of freedom and the column that matches α.

What does 2 tailed significance .000 mean? ›

Correlation is significant at the 0.01 level (2-tailed). between the two variables. The significance level is . 000, which means the relationship is highly significant (and therefore it is likely that there is a relationship between the two variables in the population as well as the sample).

What is a one-sample t test how do I interpret the results? ›

The one-sample t-test compares the mean of a single sample to a predetermined value to determine if the sample mean is significantly greater or less than that value. The independent sample t-test compares the mean of one distinct group to the mean of another group.

How do you compare if two values are significantly different? ›

The t-test gives the probability that the difference between the two means is caused by chance. It is customary to say that if this probability is less than 0.05, that the difference is 'significant', the difference is not caused by chance.

How do you statistically compare two sets of data? ›

When you compare two or more data sets, focus on four features:
1. Center. Graphically, the center of a distribution is the point where about half of the observations are on either side.
2. Spread. The spread of a distribution refers to the variability of the data. ...
3. Shape. ...
4. Unusual features.

What if sample is less than 30? ›

For example, when we are comparing the means of two populations, if the sample size is less than 30, then we use the t-test. If the sample size is greater than 30, then we use the z-test.

Does 2 sample t-test need normal data? ›

Testing for Normality and Nonparametric Tests

The samples for the two-sample t-test should come from a distribution that's close to normal. This condition is called the assumption of normality. Signs that your data does not come from a normal distribution include skewness or unusually fat tails.

Do sample sizes need to be equal for two sample t-test? ›

Is it possible to perform a t-test when the sample sizes of each group are not equal? The short answer: Yes, you can perform a t-test when the sample sizes are not equal. Equal sample sizes is not one of the assumptions made in a t-test.

What are the three conditions for t-test? ›

The conditions required to conduct a t-test include the measured values in ratio scale or interval scale, simple random extraction, homogeneity of variance, appropriate sample size, and normal distribution of data.

What is the 2 t rule of thumb? ›

RULES OF THUMB. In “big” samples, if we get a t-test bigger than 2, we can usually reject the null at the 0.05 level. This is because in “big” samples, the t-distribution is very similar to the Normal distribution, so about 5% of the distribution is above 1.96 or below -1.96.

### How do you solve t-test questions? ›

The basic idea for calculating a t-test is to find the difference between the means of the two groups and divide it by the STANDARD ERROR (OF THE DIFFERENCE) — which is the standard deviation of the distribution of differences.

How do I know if I have enough samples? ›

Large Enough Sample Condition
1. You have a symmetric distribution or unimodal distribution without outliers: a sample size of 15 is “large enough.”
2. You have a moderately skewed distribution, that's unimodal without outliers; If your sample size is between 16 and 40, it's “large enough.”

Is a sample size of 30 enough? ›

A sample size of 30 is fairly common across statistics. A sample size of 30 often increases the confidence interval of your population data set enough to warrant assertions against your findings.4 The higher your sample size, the more likely the sample will be representative of your population set.

Is it better to have more samples? ›

The larger the sample size, the more accurate the average values will be. Larger sample sizes also help researchers identify outliers in data and provide smaller margins of error.

Why is my t-test value so high? ›

Higher values of the t-score indicate that a large difference exists between the two sample sets. The smaller the t-value, the more similarity exists between the two sample sets.

What factors affect T statistics? ›

The test statistic will change based on the number of observations in your data, how variable your observations are, and how strong the underlying patterns in the data are.

What are the assumptions for using the student's two sample t-test? ›

In the two-sample t-test, the assumptions are that the observations of different individuals are outcomes of statistically independent, normally distributed, random variables, with the same expected value for all individuals within the same group, and the same variance for all individuals in both groups.

What are the assumptions when using t-test? ›

t-Test assumptions

The data are continuous. The sample data have been randomly sampled from a population. There is homogeneity of variance (i.e., the variability of the data in each group is similar). The distribution is approximately normal.

What are the conditions for a 2 sample t-test? ›

Two Sample t-test: Assumptions

The data should be approximately normally distributed. The two samples should have approximately the same variance. If this assumption is not met, you should instead perform Welch's t-test. The data in both samples was obtained using a random sampling method.

How many samples can be tested accurately using t-test? ›

T-tests are statistical hypothesis tests that you use to analyze one or two sample means. Depending on the t-test that you use, you can compare a sample mean to a hypothesized value, the means of two independent samples, or the difference between paired samples.

### How do you solve for t-test? ›

The basic idea for calculating a t-test is to find the difference between the means of the two groups and divide it by the STANDARD ERROR (OF THE DIFFERENCE) — which is the standard deviation of the distribution of differences.

What is the formula for calculating t-test? ›

You can calculate a t-value using a common t-test with the formula: t = (X‾ - μ0) / (s / √n), where X‾ is the sample mean, μ0 represents the population mean, s is the standard deviation of the sample and n stands for the size of the sample.

How to do a two tailed t-test manually? ›

Hypothesis Testing — 2-tailed test
1. Specify the Null(H0) and Alternate(H1) hypothesis.
2. Choose the level of Significance(α)
3. Find Critical Values.
4. Find the test statistic.
Nov 27, 2019

What is the minimum sample size for t-test? ›

There is no minimum sample size required to perform a t-test. In fact, the first t-test ever performed only used a sample size of four. However, if the assumptions of a t-test are not met then the results could be unreliable.

What do my t-test results mean? ›

T-Score. A large t-score, or t-value, indicates that the groups are different while a small t-score indicates that the groups are similar. Degrees of freedom refer to the values in a study that has the freedom to vary and are essential for assessing the importance and the validity of the null hypothesis.

What is the p-value for t-test? ›

T-Values and P-values

A p-value from a t test is the probability that the results from your sample data occurred by chance. P-values are from 0% to 100% and are usually written as a decimal (for example, a p value of 5% is 0.05). Low p-values indicate your data did not occur by chance.

Why do we calculate the t-value? ›

Here's why. When you perform a t-test, you're usually trying to find evidence of a significant difference between population means (2-sample t) or between the population mean and a hypothesized value (1-sample t). The t-value measures the size of the difference relative to the variation in your sample data.

How do I calculate t-test in Excel? ›

Click on the “Data” menu, and then choose the “Data Analysis” tab. You will now see a window listing the various statistical tests that Excel can perform. Scroll down to find the t-test option and click “OK”.

How do you interpret two-tailed t-test results? ›

A two-tailed test will test both if the mean is significantly greater than x and if the mean significantly less than x. The mean is considered significantly different from x if the test statistic is in the top 2.5% or bottom 2.5% of its probability distribution, resulting in a p-value less than 0.05.

Why do you use a two-tailed t-test? ›

A two-tailed test is appropriate if you want to determine if there is any difference between the groups you are comparing. For instance, if you want to see if Group A scored higher or lower than Group B, then you would want to use a two-tailed test.

### Should I use a one or two-tailed t-test? ›

If the effect can occur in: One direction: Use a one-tailed test and choose the correct alternative hypothesis. Both directions: Use a two-tailed test. Both directions, but you care about only one direction and you need the higher statistical power: Use a two-tailed test and double the significance level.

## Videos

1. T-Tests: A Matched Pair Made in Heaven: Crash Course Statistics #27
(CrashCourse)
2. Independent t-Test [unpaired t-Test]
(DATAtab)
3. Hypothesis Testing - Difference of Two Means - Student's -Distribution & Normal Distribution
(The Organic Chemistry Tutor)
4. How to do a Two Sample (Independent) t-Test in Excel 2016 (Mac and Windows)
(David Dunaetz)
5. Two Sample T Test in SPSS
(Practical Applications of Statistics in the Social Sciences)
6. Statistics 101: Two Populations, t-test with Hypothesis
(Brandon Foltz)
Top Articles
Latest Posts
Article information

Author: Nicola Considine CPA

Last Updated: 05/21/2023

Views: 5243

Rating: 4.9 / 5 (49 voted)

Author information

Name: Nicola Considine CPA

Birthday: 1993-02-26

Address: 3809 Clinton Inlet, East Aleisha, UT 46318-2392

Phone: +2681424145499

Job: Government Technician

Hobby: Calligraphy, Lego building, Worldbuilding, Shooting, Bird watching, Shopping, Cooking

Introduction: My name is Nicola Considine CPA, I am a determined, witty, powerful, brainy, open, smiling, proud person who loves writing and wants to share my knowledge and understanding with you.