# Hypothesis Testing  ## What is the Hypothesis Testing in Statistics?

Hypothesis Testing refers to the statistical tool which helps in measuring the probability of the correctness of the hypothesis result which is derived after performing the hypothesis on the sample data of the population i.e., it confirms that whether primary hypothesis results derived were correct or not.

For example, if we believe that the returns from the NASDAQ stock index are not zero.  Then the null hypothesis, in this case, is that the recovery from the NASDAQ index is zero.

### Formula

The two important parts here are the null hypothesis and the alternative hypothesis. The formula to measure the null hypothesis and the alternate hypothesis involves the and the alternative hypothesis.

H0:µ0=0

Ha: µ0≠0

Where

• H0 = null hypothesis
• Ha = alternate hypothesis

We will also need to calculate the test statistic to be able to reject the hypothesis testing.

The formula for the test statistic is represented as follows,

T= µ/(s/√n)

For eg:
Source: Hypothesis Testing (wallstreetmojo.com)

### Detailed Explanation

It has two parts: the null hypothesis and the other is known as the alternative hypothesis. The null hypothesis is the one that the researcher tries to reject. It isn’t easy to prove the alternate hypothesis, so if the null hypothesis is rejected, the remaining alternate theory gets accepted. It is tested at a different level of significance will the help of calculating the test statistics.

### Examples

You can download this Hypothesis Testing Excel template here – Hypothesis Testing Excel template

#### Example #1

Let us try to understand the concept of hypothesis testing with the help of an example. Suppose we want to know that the mean return from a portfolio over 200 days is greater than zero. The mean daily return of the sample is 0.1%, and the standard deviation is 0.30%.

In this case, the null hypothesis which the researcher would like to reject is that the mean daily return for the portfolio is zero. The null hypothesis, in this case, is a two-tail test. We will reject the null hypothesis if the statistic is outside the range of the level of significance.

At a 10% level of significance, the z-value for the two-tailed test will +/- 1.645. So if the test statistic is beyond this range, then we will reject the hypothesis.

Based on the given information, determine the test statistic.

Therefore, the calculation of test statistic will be as follows,

T= µ/(s/√n)

=0.001/(0.003/√200)

Test Statistic will be –

The test statistic is = 4.71

Since the value of the statistic is more than +1.645, then the null hypothesis will be rejected for a 10% level of significance. Therefore the alternate hypothesis is accepted for the research that the mean value of the portfolio is greater than zero.

#### Example #2

Let us try to understand the concept of hypothesis testing with the help of another example. Suppose we want to know that the mean return from a mutual fund over 365 days is more significant than zero. The mean daily return of the sample if 0.8%, and the standard deviation is 0.25%.

In this case, the null hypothesis which the researcher would like to reject is that the mean daily return for the portfolio is zero. The null hypothesis, in this case, is a two-tail test. We will reject the null hypothesis if the test statistic is outside the range of the level of significance.

At a 5% level of significance, the z-value for the two-tailed test will +/- 1.96. So if the test statistic is beyond this range, then we will reject the hypothesis.

Below is the given data for calculation of test statistic

Therefore, the calculation of test statistic will be as follows,

T= µ/(s/√n)

=.008/(.025/√365)

Test Statistic will be –

Test Statistics = 61.14

Since the value of the test statistic is more than +1.96, then the null hypothesis will be rejected for a 5% level of significance. Therefore the alternate theory is accepted for the research that the mean value of the portfolio is more significant than zero.

#### Example #3

Let us try to understand the concept of hypothesis testing with another example for a different level of significance. Suppose we want to know that the mean return from an options portfolio over 50 days is greater than zero. The mean daily return of the sample if 0.13%, and the standard deviation is 0.45%.

In this case, the null hypothesis which the researcher would like to reject is that the mean daily return for the portfolio is zero. The null hypothesis, in this case, is a two-tail test. We will reject the null hypothesis if the test statistic is outside the range of the level of significance.

At a 1% level of significance, the z-value for the two-tailed test will +/- 2.33. So if the test statistic is beyond this range, then we will reject the hypothesis.

Use the following data for the calculation of test statistic

So, the calculation of test statistic can be done as follows-

T= µ/(s/√n)

=.0013/ (.0045/√50)

Test Statistic will be –

The test statistic is = 2.04

Since the value of the test statistic is less than +2.33, then the null hypothesis cannot be rejected for a 1% level of significance. Therefore the alternate hypothesis is rejected for the research that the of the portfolio is greater than zero.

### Relevance and Use

It is a statistical method done to test a particular theory and has two parts: the null hypothesis and the other is known as the alternative hypothesis. The null hypothesis is the one that the researcher tries to reject. It isn’t easy to prove the alternate hypothesis, so if the null hypothesis is rejected, the remaining alternate theory gets accepted.

It is a critical test to validate a theory. In practice, it is difficult to validate an approach statistically. That’s why a researcher tries to reject the null hypothesis to validate the alternate idea. It plays a vital role in accepting or rejecting decisions in businesses.

### Recommended Articles

This has been a guide to Hypothesis Testing Formula. Here we discuss the calculation of Hypothesis Testing with practical examples and a downloadable excel template. You can learn more about excel modeling from the following articles –