You are on page 1of 21

Hypothesis Testing

Introduction
Hypothesis:-

A proposed explanation made on the basis of limited evidence as a starting point for further investigation.
Simply it is an educated guess. When it can be tested then it is said to be a scientific

hypothesis.

Statistical hypothesis testing is a way of testing

scientific hypothesis based on collected data from a scientific study.

Introduction
Null Hypothesis(H0):-

This reflects that there will be no observed effect for our experiment. Null hypothesis is what we are attempting to overturn by our hypothesis test.
Example:Person is assumed to innocent until proven guilty.

Introduction
Alternative Hypothesis(H1):-

This is also known as experimental hypothesis. This reflects that there will be an observed effect for our experiment.
Alternative hypothesis is what we are attempting to

demonstrate in an indirect way by the use of our hypothesis test.

Examples
There is a claim that average GPA of SLIIT student is

3.2.
There is a claim that mobile phone user in Sri Lanka

is spending more than Rs.300/= per month for the mobile usage.

Examples

Introduction
Test Statistic:-

A numerical value which summarizes the information contained in the sample data and which is a basis for testing a given hypothesis.
Rejection Criteria:-

Also known as the decision rule.

Directional & Non Directional Tests

Some Principles
H0 is presumed true unless overwhelming evidence

rejects it. E.g., H0: defendant is not guilty!

Sample data give test statistics for , p or 2

We reject the Null H0 if statistic falls in Rejection Region


Instead of saying Accept one says Fails to Reject. Absolute certainty does not exist.

Type Of Errors

Steps of Hypothesis Testing


Formulation of null and alternative hypothesis. Identification of correct test statistic for the

evaluation of hypothesis with a significance level.

Compare the results with the rejection criterion State whether the hypothesis can be accepted or

rejected based on some confidence level(significance level can also be used).

Hypothesis Testing For Mean


(Single Population)

Formulation of hypothesis
Identification of correct test statistic

If population variance is known(population truly or approximately normal distribution) then

~ (0,1)

Hypothesis Testing For Mean


(Single Population)

If

population variance is unknown(population truly or approximately normal distribution)


If

sample size 30

~ (, )

If

sample size < 30

Example 1
Execution time of a specific algorithm is 1.325

minutes. From the experience it is known that standard deviation of the execution time is 0.0396minutes. Changes in the execution time may cause a bottleneck. For a recent random samples of 80, mean execution time was 1.3229 minutes. Does the algorithm need to be adjusted?

Example 1

Example 2
Robotic arm in a production line takes 103 seconds

to move from one line to another line with a standard deviation of 4 seconds . If the arm takes more than 103 seconds move between the lines it affects the other tasks in the production line. Time was measured for 40 samples to move between lines and mean values was 104 seconds. Will the operating time of robotic arm affects the other tasks?

Example 3
New method was developed to connect two mobile

phones. With the existing methods it takes 1015 seconds to make the connection between the phones. 25 Mobile sets(mobile set consisting of two mobile phones) were used to measure the connection time. Mean connection time was 1010 seconds and standard deviation was 15. If the connection time approximately follows a normal distribution what can you say about the new connection method?

Hypothesis Testing For Population


(Single Population)

Test Statistic

==


()

~ (, )

Example
Advertisement of a certain university is saying that

70% of the graduates from their university enter the job market in a position directly related to their undergraduate field of study. In a sample of 200 of the graduates only 66% have entered jobs related to the field of their study. What can you say about the claim of the advertisement.

Hypothesis Testing For Mean


(Two Sample Case)

Hypothesis Testing For Mean


(Two Sample Case)

You might also like