Reading Time: 6 minutes

The T.TEST function in Google Sheets allows you to compare the mean of two different samples and determine if there is a statistical difference between them. In this article, we will explore how to use the T.TEST function in Google Sheets to perform various types of T.TESTs.

## What are T.TESTS?

T.TESTS are used to compare the mean of two different samples and determine if there is a statistical difference between them. In Google Sheets, the T.TEST function calculates the probability value of a T.TEST. To perform this test, statisticians use a method called hypothesis testing. The null hypothesis assumes that the means of the two samples are equal, while the alternate hypothesis states that the means are not equal. By using the T.TEST function in Google Sheets, we can test these hypotheses. Three important factors are considered for each sample: the difference between the means, the standard deviations of the samples, and the number of data values.

## Why perform T.TESTS?

Statisticians use T.TESTS to check if two data sets are equal or closely related for various reasons. For example, in medical research, experiments can be conducted on two samples, such as a placebo group and a second group. By using the T.TEST function, researchers can determine if there is a significant difference in the results between the two groups.

## How to use the T.TEST function in Google Sheets

The T.TEST function in Google Sheets allows you to perform all kinds of T.TESTs directly in your worksheets. It is important to note that the T.TEST function tests two data samples, and if you need to test more than two samples, you may need to use other tests such as the Z-tests, ANOVA test, or F-tests.

Now, let’s look at how to use the T.TEST function in Google Sheets to perform all three types of T.TESTs.

### Example 1: Performing a paired T.TEST

To perform a paired sample T.TEST, follow these steps:

#### Step 1: Provide the data sample

Use the provided data set, which represents the test scores of 11 pupils in a class before and after a seminar. Column B contains the before values, and column C contains the after values. We will use the before data as a control group to determine if the seminar truly impacted each student’s performance.

#### Step 2: Enter the T.TEST function in Google Sheets

In an empty cell, preferably the same as used in this tutorial (E4), enter the T.TEST function, `=T.TEST`

.

Select the T.TEST function from the auto-suggested options.

#### Step 3: Enter the parameters for the T.TEST function

Now, provide the parameters necessary to perform a paired T.TEST:

- Set range 1 to B4:B14
- Set range 2 to C4:C14
- Set the tails to 2
- Finally, set the type to 1 indicating that we want to perform a paired T.TEST

The full formula will be as shown below:

`=T.TEST(B4:B14, C4:C14, 2, 1)`

From the obtained result, 0.1293526467, we can infer that our null hypothesis is false since the p-value > 0.05.

### Example 2: Two sample equal variance test

To perform a two-sample equal variance test, use the provided data:

To test if the means of the two samples are equal, follow these steps:

- Set range 1 to A4:A14
- Set range 2 to B4:B14
- Set the tails to 1
- Finally, set the type to 2 indicating that we want to perform a two-sample equal variance T.TEST

The formula will be:

`=T.TEST(A4:A14, B4:B14, 2, 2)`

By comparing the obtained p-value with 0.05, we can conclude that the two samples have significantly different means.

### Example 3: Two sample unequal variance test

To perform a two-sample unequal variance test, modify the data set by making one sample longer than the other:

- Set range 1 to A4:A14
- Set range 2 to B4:B17
- Set the tails to 2
- Set the type to 3 to perform a two-sample unequal variance T.TEST

The formula will be:

`=T.TEST(A4:A14, B4:B17, 2, 3)`

Since the obtained p-value > 0.05, we can conclude that the two samples have significantly different means.

The T.TEST function in Google Sheets helps determine the relationship between two datasets by testing the difference between their means.

## Some related questions

### What are the types of T.TESTS?

To perform T.TESTS in Google Sheets, it is important to know the different types. Broadly speaking, there are two types of T.TESTs:

- A paired T.TEST is used for testing samples from a single population, such as before and after treatment of a particular group. This is also known as a dependent T.TEST.
- Two-sample T.TEST is used when two samples come from different populations. This kind of test is further divided into two: equal variance and unequal variance two-sample T.TESTs. In the former, the data sets are equal in length, while they are unequal in the latter. This is known as an independent T.TEST.

### How do you find the p-value from T.TEST in Google Sheets?

The p-value is the value obtained using the T.TEST function in Google Sheets. To find the p-value, simply supply the required parameters to the function. For example, in the T.TEST function `=T.TEST(B4:B14, C4:C14, 2, 1)`

, where B4:B14 is range 1, C4:C14 is range 2, the tails are 2, and the type is 1. Compare the obtained p-value to a significance level of 0.05 to determine the relationship between the means.

Don’t miss other interesting articles on our blog, such as How to find P-value in Google Sheets and How To Use The Z.TEST function in Google Sheets.