Survey
* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
Hypothesis testing Inferental statistics Estimation Hypothesis testing Estimation of a population parameter from a sample - Point - Interval Hypothesis testing is a procedure, based on sample evidence and probability theory, used to determine whether the hypothesis is a reasonable statement and should not be rejected, or is unreasonable and should be rejected. No nothing about the population parameter We have a preliminary idea about the population parameter Previous class: estimation Application of Hypothesis testing 1. Is there a significant objectives/properites? difference between 2. Is there a significant relationship between/among variables? Meaning of Hypothesis testing (1) 1. Starting point: we have an idea about the population -> we expect that the sample shows our idea Research question Statistical formulation • Null Hypothesis H0: A statement about the value of a population parameter. It contains „=„ • Alternative Hypothesis H1: Negotiation of H0 State Hypothesis Nullhypothesis H0 Negation: alternate hypothesis H1 H0 : No significance relationship H0 : No significance difference H0 : Always contains „=„ symbol Example Compare the life expectancy of men and Women State H0 and H1 Meaning of Hypothesis testing (2) 2. Compare the difference between the sample and our idea with a formula formula : test function If there is no difference the value is 0 Higher difference means higher value of test function result: value of test function 3. Make a decision: Is the difference significant? -> make a decision on our idea Steps of Hypothesis Testing Chart Title Step 1: State null and alternate hypotheses Step 2: Select a statistical tests Step 3: Compute the value of test statistic Step 4: Setup decision rules Step 5: Make a decision Do not reject null Reject null and accept alternate Errors when we make decision H0 true H0 not true Retain H0 Right decision (1-a) Error Type II ( b) Reject H0 Error Type I (a) Right decision (1-b) Usage of spss Search p-value, sig.. If sig<0,05 -> Reject H0 Else Retain H0 Definitions Level of Significance: The probability of rejecting the null hypothesis when it is actually true. Type I Error: Rejecting the null hypothesis when it is actually true. Type II Error: Accepting the null hypothesis when it is actually false A classification of tests According the number of samples One sample Two samples More than 2 samples ONE SAMPLE TESTS We will examine Distribution of a variable Population mean Population standard. deviation A proportion in the Population Testing for the Population Mean Population standard Population standard deviation (σ) is deviation (σ) is not known known X 0 z / n X 0 t s/ n When can we use z or t statistics? If n>=100 If 30<=n<100 but the distribution is not skewed to the right strongly (skewness<+1) If n<30 and there is a normal distribution EXAMPLE 1 The processors of Fries’ Catsup indicate on the label that the bottle contains 16 ounces of catsup. The standard deviation of the process is 0.5 ounces. A sample of 36 bottles from last hour’s production revealed a mean weight of 16.12 ounces per bottle. At the 0.05 significance level can we conclude that the mean amount per bottle is different from 16 ounces if the weight distribution is normal. EXAMPLE 1 continued Step 1: State the null and the alternative hypotheses: H0: = 16; H1: 16 Step 2: Identify the test statistic. Because we know the population standard deviation, the test statistic is z. Step 3: Compute test statistics. X 0 16.12 16.00 z 1.44 n 0.5 36 EXAMPLE 1 continued Step 4: State the decision rule: z0.975=1.96 Retain H0 if z is within (-1.96;1.96) Step 5: Make a decision Retain the null hypothesis. We cannot conclude the mean is different from 16 ounces. EXAMPLE 2 Roder’s Discount Store chain issues its own credit card. Lisa, the credit manager, wants to find out if the mean monthly unpaid balance is more than $400. The level of significance is set at 0.05. A random check of 172 unpaid balances revealed the sample mean to be $407 and the sample standard deviation to be $38. Should Lisa conclude that the population mean is greater than $400? EXAMPLE 2 continued Step 1: H0: µ <400, H1: µ > $400 Step 2: Because standard deviation of the population is not known we can use the t distribution as the test statistic. Step 3: Compute test statisics X 0 $407 $400 t 2.42 s n $38 172 EXAMPLE 2 continued • Step 4: Decision rule: t0.95(171)=1.65 Retain H0 if t is within (-∞;1.65) • Step 5: Make a decision. H0 is rejected. Lisa can conclude that the mean unpaid balance is greater than $400. Example 3 The current rate for producing 5 amp fuses at Neary Electric Co. is 250 per hour. A new machine has been purchased and installed that, according to the supplier, will increase the production rate. A sample of 10 randomly selected hours from last month revealed the mean hourly production on the new machine was 256 units, with a sample standard deviation of 6 per hour. It is also known that the hourly production follow a normal distribution. At the 0.05 significance level can Neary conclude that the new machine is faster? Example 3 continued Step 1: State the null and the alternate hypothesis. H0: µ<250; H1: µ > 250 Step 2: Find a test statistic. It is the t distribution because the population standard deviation is not known and the sample size is less than 30, but normal distribution is assumed. Step 3: Compute a test statistic. X 0 256 250 t 3.162 s n 6 10 Example 3 continued Step 4: State the decision rule. t0.95(9)=1.833 Retain H0 if t is within (-∞;1.833) Step 5: Make a decision. The null hypothesis is rejected. The mean number produced is more than 250 per hour. Tests Concerning Proportion A Proportion is the fraction or percentage that indicates the part of the population or sample having a particular trait of interest. The sample proportion is denoted by p and is found by: Number of successesin the sample p Number sampled Test Statistic for Testing a Single Population Proportion z p 0 0 (1 0 ) n The sample proportion is p and π is the population proportion. EXAMPLE 4 In the past, 15% of the mail order solicitations for a certain charity resulted in a financial contribution. A new solicitation letter that has been drafted is sent to a sample of 200 people and 45 responded with a contribution. At the 0.05 significance level can it be concluded that the new letter is more effective? Example 4 continued Step 1: State the null and the alternate hypothesis. H0: π< 0.15 H1: π > 0.15 Step 2: Find a test statistic. The z distribution is the test statistic. 45statistic. Step 3: Compute the test 0.15 p 0 200 z 2.97 0 (1 0 ) 0.15(1 0.15) 200 n Example 4 continued • Step 4: State the decision rule. z0.95=1.65 Retain H0 if z is within (-∞;1.65) • Step 5: Make a decision. The null hypothesis is rejected. More than 15 percent are responding with a pledge. The new letter is more effective.