Z-TEST / Z-STATISTIC: used to test hypotheses about µ whe the populatio stadard deviatio is kow ad populatio distributio is ormal or sample size is large T-TEST / T-STATISTIC: used to test hypotheses about µ whe the populatio stadard deviatio is ukow Techically, requires populatio distributios to be ormal, but is robust with departures from ormality Sample size ca be small The oly differece betwee the z- ad t-tests is that the t-statistic estimates stadard error by usig the sample stadard deviatio, while the z-statistic utilizes the populatio stadard deviatio Formula: Oe Sample T-test t = x µ where = s = estimated stadard error of the mea Because we re usig sample data, we have to correct for samplig error. The method for doig this is by usig what s called degrees of freedom 1
Degrees of Freedom degrees of freedom ( ) are defied as the umber of scores i a sample that are free to vary we kow that i order to calculate variace we must kow the mea ( ) this limits the umber of scores that are free to vary df = 1 X s = df ( x i x ) 1 where is the umber of scores i the sample Degrees of Freedom Cot. Picture Example There are five balloos: oe blue, oe red, oe yellow, oe pik, & oe gree. If 5 studets (=5) are each to select oe balloo oly 4 will have a choice of color (df=4). The last perso will get whatever color is left.
The particular t-distributio to use depeds o the umber of degrees of freedom(df) there are i the calculatio Degrees of freedom (df) df for the t-test are related to sample size For sigle-sample t-tests, df= -1 df cout how may observatios are free to vary i calculatig the statistic of iterest For the sigle-sample t-test, the limit is determied by how may observatios ca vary i calculatig s i t obt = x µ s z obt = x µ σ The z-test assumes that: the umerator varies from oe sample to aother the deomiator is costat Thus, the samplig distributio of z derives from the samplig distributio of the mea Z-test vs. T-test t obt = x µ s The z-test assumes that: the umerator varies from oe sample to aother the deomiator varies from oe sample to aother Therefore the samplig distributio is broader tha it otherwise would be The samplig distributio chages with It approaches ormal as icreases 3
Characteristics of the t-distributio: The t-distributio is a family of distributios -- a slightly differet distributio for each sample size (degrees of freedom) It is flatter ad more spread out tha the ormal z-distributio As sample size icreases, the t-distributio approaches a ormal distributio Itroductio to the t-statistic 3.5 3 t-dist., df=5.5 Normal Distributio, df= t-dist., df=0 1.5 1 t-dist., df=1 0.5 0-3 - -1 0 1 3 Whe df are large the curve approximates the ormal distributio. This is because as is icreased the estimated stadard error will ot fluctuate as much betwee samples. 4
Note that the t-statistic is aalogous to the z- statistic, except that both the sample mea ad the sample s.d. must be calculated Because there is a differet distributio for each df, we eed a differet table for each df Rather tha actually havig separate tables for each t-distributio, Table D i the text provides the critical values from the tables for df= 1 to df= 10 As df icreases, the t-distributio becomes icreasigly ormal For df=, the t-distributio is Procedures i doig a t-test 1. Determie H 0 ad H 1. Set the criterio Look up t crit, which depeds o alpha ad df 3. Collect sample data, calculate x ad s 4. Calculate the test statistic t obt = x µ s 5. Reject H 0 if t obt is more extreme tha t crit 5
Example: A populatio of heights has a µ=68. What is the probability of selectig a sample of size =5 that has a mea of 70 or greater ad a s=4? We hypothesized about a populatio of heights with a mea of 68 iches. However, we do ot kow the populatio stadard deviatio. This tells us we must use a t-test istead of a z-test Step 1: State the hypotheses H 0 : µ=68 H 1 : µ 68 6
Step : Set the criterio oe-tail test or two-tail test? α=? df = -1 =? See table for critical t-value Step 3: Collect sample data, calculate x ad s From the example we kow the sample mea is 70, with a stadard deviatio (s) of 4. Step 4: Calculate the test statistic Calculate the estimated stadard error of the mea = s = 4 5 = 0.8 Calculate the t-statistic for the sample x µ t = t = 70 68 0.8 =.5 7
Step 5: Reject H 0 if t obt is more extreme tha t crit The critical value for a oe-tailed t-test with df=4 ad α=.05 is 1.711 Will we reject or fail to reject the ull hypothesis? 4 3 1 0 t crit =1.711 0.05 Example: A researcher is iterested i determiig whether or ot review sessios affect exam performace. The idepedet variable, a review sessio, is admiistered to a sample of studets (=9) i a attempt to determie if this has a effect o the depedet variable, exam performace. Based o iformatio gathered i previous semesters, I kow that the populatio mea for a give exam is 4. The sample mea is 5, with a stadard deviatio (s) of 4. 8
We hypothesized about a populatio mea for studets who get a review based o the iformatio from the populatio who did t get a review (µ=4). However, we do ot kow the populatio stadard deviatio. This tells us we must use a t-test istead of a z- test Step 1: State the hypotheses H 0 : µ=4 H 1 : µ 4 Step : Set the criterio oe-tail test or two-tail test? α=? df = -1 =? See table for critical t-value Step 3: Collect sample data, calculate x ad s From the example we kow the sample mea is 5, with a stadard deviatio (s) of 4. 9
Step 4: Calculate the test statistic Calculate the estimated stadard error of the mea s 4 4 = = = = 1.33 9 3 Calculate the t-statistic for the sample x µ t = 6 4 t = = 1.33 1.33 = 1.503 Step 5: Reject H 0 if t obt is more extreme tha t crit The critical value for a oe-tailed t-test with df=8 ad α=.05 is 1.86 Will we reject or fail to reject the ull hypothesis? 4 3 1 0 0.05 t crit =-.101 α t + α crit =.101 0.05 10
Assumptios of the t-test: Idepedet Observatios: Each perso s score i the sample is ot affected by other scores; if, for example, subjects cheated from oe aother o the exam, the idepedece assumptio would be violated Normality: The populatio sampled must be ormally distributed Need to kow oly the populatio mea Need sample mea ad stadard deviatio Cofidece Itervals Ofte, oe s iterest is ot i testig a hypothesis, but i estimatig a populatio mea or proportio This caot be doe precisely, but oly to some extet Thus, oe estimates a iterval, ot a poit value The iterval cotais the true value with a probability The wider the iterval, the greater the probability that it cotais the true value Thus there is a precisio/cofidece trade-off The itervals are called cofidece itervals(ci) Typical CIs cotai the true value with probability.95 (95% CI) ad with probability.99 (99% CI) CI is calculated with either t or z, as appropriate 11