Z-test

A Z-test is any statistical test for which the distribution of the test statistic under the null hypothesis can be approximated by a normal distribution. Z-test tests the mean of a distribution. For each significance level in the confidence interval, the Z-test has a single critical value (for example, 1.96 for 5% two tailed) which makes it more convenient than the Student's t-test whose critical values are defined by the sample size (through the corresponding degrees of freedom). Both the Z-test and Student's t-test have similarities in that they both help determine the significance of a set of data. However, the z-test is rarely used in practice because the population deviation is difficult to determine.

Applicability

Because of the central limit theorem, many test statistics are approximately normally distributed for large samples. Therefore, many statistical tests can be conveniently performed as approximate Z-tests if the sample size is large or the population variance is known. If the population variance is unknown (and therefore has to be estimated from the sample itself) and the sample size is not large (n < 30), the Student's t-test may be more appropriate (in some cases, n < 50, as described below).

Procedure

How to perform a Z test when T is a statistic that is approximately normally distributed under the null hypothesis is as follows:

First, estimate the expected value μ of T under the null hypothesis, and obtain an estimate s of the standard deviation of T.

Second, determine the properties of T : one tailed or two tailed.

For Null hypothesis H0: μ≥μ0 vs alternative hypothesis H1: μ<μ0 , it is lower/left-tailed (one tailed).

For Null hypothesis H0: μ≤μ0 vs alternative hypothesis H1: μ>μ0 , it is upper/right-tailed (one tailed).

For Null hypothesis H0: μ=μ0 vs alternative hypothesis H1: μ≠μ0 , it is two-tailed.

Third, calculate the standard score: which one-tailed and two-tailed p-values can be calculated as Φ(Z)(for lower/left-tailed tests), Φ(−Z) (for upper/right-tailed tests) and 2Φ(−|Z|) (for two-tailed tests) where Φ is the standard normal cumulative distribution function.

Use in location testing

  1. The term "Z-test" is often used to refer specifically to the one-sample location test comparing the mean of a set of measurements to a given constant when the sample variance is known. For example, if the observed data X1, ..., Xn are (i) independent, (ii) have a common mean μ, and (iii) have a common variance σ2, then the sample average X has mean μ and variance .
  2. The null hypothesis is that the mean value of X is a given number μ0. We can use X  as a test-statistic, rejecting the null hypothesis if X − μ0 is large.
  3. To calculate the standardized statistic , we need to either know or have an approximate value for σ2, from which we can calculate . In some applications, σ2 is known, but this is uncommon.
  4. If the sample size is moderate or large, we can substitute the sample variance for σ2, giving a plug-in test. The resulting test will not be an exact Z-test since the uncertainty in the sample variance is not accounted for—however, it will be a good approximation unless the sample size is small.
  5. A t-test can be used to account for the uncertainty in the sample variance when the data are exactly normal.
  6. Difference between Z-test and t-test: Z-test is used when sample size is large (n>50), or the population variance is known. t-test is used when sample size is small (n<50) and population variance is unknown.
  7. There is no universal constant at which the sample size is generally considered large enough to justify use of the plug-in test. Typical rules of thumb: the sample size should be 50 observations or more.
  8. For large sample sizes, the t-test procedure gives almost identical p-values as the Z-test procedure.
  9. Other location tests that can be performed as Z-tests are the two-sample location test and the paired difference test.

Conditions

For the Z-test to be applicable, certain conditions must be met.

  • Nuisance parameters should be known, or estimated with high accuracy (an example of a nuisance parameter would be the standard deviation in a one-sample location test). Z-tests focus on a single parameter, and treat all other unknown parameters as being fixed at their true values. In practice, due to Slutsky's theorem, "plugging in" consistent estimates of nuisance parameters can be justified. However, if the sample size is not large enough for these estimates to be reasonably accurate, the Z-test may not perform well.
  • The test statistic should follow a normal distribution. Generally, one appeals to the central limit theorem to justify assuming that a test statistic varies normally. There is a great deal of statistical research on the question of when a test statistic varies approximately normally. If the variation of the test statistic is strongly non-normal, a Z-test should not be used.

If estimates of nuisance parameters are plugged in as discussed above, it is important to use estimates appropriate for the way the data were sampled. In the special case of Z-tests for the one or two sample location problem, the usual sample standard deviation is only appropriate if the data were collected as an independent sample.

In some situations, it is possible to devise a test that properly accounts for the variation in plug-in estimates of nuisance parameters. In the case of one and two sample location problems, a t-test does this.

Example

Suppose that in a particular geographic region, the mean and standard deviation of scores on a reading test are 100 points, and 12 points, respectively. Our interest is in the scores of 55 students in a particular school who received a mean score of 96. We can ask whether this mean score is significantly lower than the regional mean—that is, are the students in this school comparable to a simple random sample of 55 students from the region as a whole, or are their scores surprisingly low?

First calculate the standard error of the mean:

where is the population standard deviation.

Next calculate the z-score, which is the distance from the sample mean to the population mean in units of the standard error:

In this example, we treat the population mean and variance as known, which would be appropriate if all students in the region were tested. When population parameters are unknown, a Student's t-test should be conducted instead.

The classroom mean score is 96, which is −2.47 standard error units from the population mean of 100. Looking up the z-score in a table of the standard normal distribution cumulative probability, we find that the probability of observing a standard normal value below −2.47 is approximately 0.5 − 0.4932 = 0.0068. This is the one-sided p-value for the null hypothesis that the 55 students are comparable to a simple random sample from the population of all test-takers. The two-sided p-value is approximately 0.014 (twice the one-sided p-value).

Another way of stating things is that with probability 1 − 0.014 = 0.986, a simple random sample of 55 students would have a mean test score within 4 units of the population mean. We could also say that with 98.6% confidence we reject the null hypothesis that the 55 test takers are comparable to a simple random sample from the population of test-takers.

The Z-test tells us that the 55 students of interest have an unusually low mean test score compared to most simple random samples of similar size from the population of test-takers. A deficiency of this analysis is that it does not consider whether the effect size of 4 points is meaningful. If instead of a classroom, we considered a subregion containing 900 students whose mean score was 99, nearly the same z-score and p-value would be observed. This shows that if the sample size is large enough, very small differences from the null value can be highly statistically significant. See statistical hypothesis testing for further discussion of this issue.

Occurrence and applications

For maximum likelihood estimation of a parameter

Location tests are the most familiar Z-tests. Another class of Z-tests arises in maximum likelihood estimation of the parameters in a parametric statistical model. Maximum likelihood estimates are approximately normal under certain conditions, and their asymptotic variance can be calculated in terms of the Fisher information. The maximum likelihood estimate divided by its standard error can be used as a test statistic for the null hypothesis that the population value of the parameter equals zero. More generally, if is the maximum likelihood estimate of a parameter θ, and θ0 is the value of θ under the null hypothesis,

can be used as a Z-test statistic.

When using a Z-test for maximum likelihood estimates, it is important to be aware that the normal approximation may be poor if the sample size is not sufficiently large. Although there is no simple, universal rule stating how large the sample size must be to use a Z-test, simulation can give a good idea as to whether a Z-test is appropriate in a given situation.

Z-tests are employed whenever it can be argued that a test statistic follows a normal distribution under the null hypothesis of interest. Many non-parametric test statistics, such as U statistics, are approximately normal for large enough sample sizes, and hence are often performed as Z-tests.


Comparing the proportions of two binomials

The z-test for comparing two proportions is a statistical method used to evaluate whether the proportion of a certain characteristic differs significantly between two independent samples. This test leverages the property that the sample proportions (which is the average of observations coming from a Bernoulli distribution) are asymptotically normal under the Central Limit Theorem, enabling the construction of a z-test.

The z-statistic for comparing two proportions is computed using:

Where:

  • = sample proportion in the first sample
  • = sample proportion in the second sample
  • = size of the first sample
  • = size of the second sample
  • = pooled proportion, calculated as , where and are the counts of successes in the two samples.

The confidence interval for the difference between two proportions, based on the definitions above, is:

Where:

  • is the critical value of the standard normal distribution (e.g., 1.96 for a 95% confidence level).

The MDE for when using the (two-sided) z-test formula for comparing two proportions, incorporating critical values for and , and the standard errors of the proportions:[1][2]

Where:

  • : Critical value for the significance level.
  • : Quantile for the desired power.
  • : When assuming the null is correct.

See also

References

  1. ^ COOLSerdash (https://stats.stackexchange.com/users/21054/coolserdash), Two proportion sample size calculation, URL (version: 2023-04-14): https://stats.stackexchange.com/q/612894
  2. ^ Chow S-C, Shao J, Wang H, Lokhnygina Y (2018): Sample size calculations in clinical research. 3rd ed. CRC Press.

Further reading

  • Sprinthall, R. C. (2011). Basic Statistical Analysis (9th ed.). Pearson Education. ISBN 978-0-205-05217-2.
  • Casella, G., Berger, R. L. (2002). Statistical Inference. Duxbury Press. ISBN 0-534-24312-6.
  • Douglas C.Montgomery, George C.Runger.(2014). Applied Statistics And Probability For Engineers.(6th ed.). John Wiley & Sons, inc. ISBN 9781118539712, 9781118645062.

Read other articles:

Ramallah رام الله • רמאללהKotaSearah jarum jam dari atas:Cakrawala Ramallah dan Masjid Pusat, Makam Arafat, Gereja Annunciation, Reruntuhan Romawi dan Al-Manara Square Lambang kebesaran RamallahLambang kebesaranRamallahLokasi ibu kota Ramallah di PalestinaKoordinat: 31°54′N 35°12′E / 31.900°N 35.200°E / 31.900; 35.200Koordinat: 31°54′N 35°12′E / 31.900°N 35.200°E / 31.900; 35.200Negara PalestinaPemerintahan...

 

 

Souliote War (1789–1793)Part of the Russo-Turkish War (1787–1792)Ali PashaDateFebruary 1789 – April 1793LocationSouliot ConfederationPashalik of YaninaResult Souliote victoryBelligerents Souliotes Ibrahim Pasha of Vlorë Mustafa Pasha of Delvinë Cham aghas Gjirokastër beys Pashalik of YaninaCommanders and leaders Georgios Botsaris Lambros Tzavelas Ibrahim Pasha of Vlorë Mustafa Pasha of Delvinë Ali Pasha of IoanninaStrength 10,000–20,000 vteRusso-Turkish War (1787–1792)Austro-Tu...

 

 

Chinese airline Shandong Airlines山东航空集团 IATA ICAO Callsign SC CDG SHANDONG Founded12 March 1994; 30 years ago (1994-03-12)HubsJinanQingdaoFocus citiesBeijing–CapitalChongqingXiamenYantai–PenglaiFrequent-flyer programPhoenix MilesFleet size127Destinations73[1]Parent companyAir China (22.8%)HeadquartersShandong Airlines Center, Second Ring Road East No. 5746, Lixia District, Jinan, ShandongKey peopleXu Chuanyu (President)Websitewww.sda.cn Shandong Airli...

† Человек прямоходящий Научная классификация Домен:ЭукариотыЦарство:ЖивотныеПодцарство:ЭуметазоиБез ранга:Двусторонне-симметричныеБез ранга:ВторичноротыеТип:ХордовыеПодтип:ПозвоночныеИнфратип:ЧелюстноротыеНадкласс:ЧетвероногиеКлада:АмниотыКлада:Синапсиды�...

 

 

追晉陸軍二級上將趙家驤將軍个人资料出生1910年 大清河南省衛輝府汲縣逝世1958年8月23日(1958歲—08—23)(47—48歲) † 中華民國福建省金門縣国籍 中華民國政党 中國國民黨获奖 青天白日勳章(追贈)军事背景效忠 中華民國服役 國民革命軍 中華民國陸軍服役时间1924年-1958年军衔 二級上將 (追晉)部队四十七師指挥東北剿匪總司令部參謀長陸軍�...

 

 

Bahasa Novial novial Dituturkan diSeluruh duniaWilayah—Penutur— Rumpun bahasaBahasa buatan Status resmiBahasa resmi ditak adaKode bahasaISO 639-1tidak adaISO 639-2artISO 639-3–  Portal BahasaL • B • PW        Cari artikel bahasa  Cari berdasarkan kode ISO 639 (Uji coba)  Kolom pencarian ini hanya didukung oleh beberapa antarmuka Halaman bahasa acak Bendera Bahasa Novial Novial ialah bahasa pembantu internasional y...

Paul RobesonPaul Robeson nel 1942 Nazionalità Stati Uniti GenereGospelFolkMusical Periodo di attività musicaleanni 1910 – 1976 Modifica dati su Wikidata · Manuale Premio Lenin per la pace 1952Paul LeRoy Bustill Robeson (Princeton, 9 aprile 1898 – Filadelfia, 23 gennaio 1976) è stato un attore, cantante baritono-basso, poliglotta, avvocato e attivista per i diritti civili statunitense. Indice 1 Biografia 1.1 I primi anni e il successo 1.2 Gli anni della Gue...

 

 

Parapsychological and spiritual concept For other uses, see Aura. Representation of a human aura, after a diagram by Walter John Kilner (1847–1920) New Age beliefsGathering of the Rainbow Family Concepts 2012 phenomenon Ashtar Aura Chakra Deva Earth Changes Earth mysteries Energy Eternal Now Higher self Huna Indigo children Perennial philosophy Psychometry Pyramid power Quantum mysticism Self-help books Soulmate Spiritual but not religious Star people Third eye Spiritual practices Affirmati...

 

 

  「俄亥俄」重定向至此。关于其他用法,请见「俄亥俄 (消歧义)」。 俄亥俄州 美國联邦州State of Ohio 州旗州徽綽號:七葉果之州地图中高亮部分为俄亥俄州坐标:38°27'N-41°58'N, 80°32'W-84°49'W国家 美國加入聯邦1803年3月1日,在1953年8月7日追溯頒定(第17个加入联邦)首府哥倫布(及最大城市)政府 • 州长(英语:List of Governors of {{{Name}}}]]) •&...

This article is about the historical monarchs of Poland, from the Middle Ages to 1795. For presidents and other heads of state of Poland, during the 20th and 21st centuries, see List of heads of state of Poland. Monarchy of PolandRoyal coat of armsStanislaus II Augustus DetailsStyle Royal Majesty (HRM)[2]Wasza Królewska Mość Serene Reigning MajestyJaśnie Panujący Mości[3] Grace (HG)Wasza Miłość Highness (HH)Wasza Wysokość First monarch Mieszko I (as Duke) Bole...

 

 

هيئة الصحة (دبي) تفاصيل الوكالة الحكومية البلد الإمارات العربية المتحدة  المركز أم هرير25°14′51″N 55°19′09″E / 25.2475°N 55.31916667°E / 25.2475; 55.31916667    الإدارة موقع الويب الموقع الرسمي  تعديل مصدري - تعديل   هيئة الصحة هي هيئة التي تعني بالشؤوون الصحية في إمارة دب�...

 

 

ساعة يد. ساعة رُسْغ[1] أو ساعة اليد هي آلة صغيرة تقيس الوقت (ساعة)، يستخدمها الناس للتعرف على الوقت وهي تطور لساعة كانت تحمل في الجيب.[2][3] نبذة تاريخية يُنسب الفضل في صناعة أول ساعة صغيرة، تاريخيًا، إلى بيتر هينلاين، صانع الأقفال الألماني؛ فقد اخترع هينلاين في مط�...

1995 French filmDust of LifePoussières de vieDirected byRachid BoucharebWritten byDuyen Anh (novel)Rachid BoucharebBernard GesbertProduced byJean BréhatStarringDaniel GuyantGilles ChitlaphoneJehan PagèsÉric NguyenLina ChuaR. Shukor KaderCinematographyYoucef SahraouiEdited byHélène DucretMusic bySafy BoutellaDistributed bySwift DistributionRelease date 18 January 1995 (1995-01-18) Running time87 minutesCountriesFranceAlgeriaBelgiumGermanyHong KongLanguageFrench Dust of Li...

 

 

Indian music company This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these template messages) This article includes a list of general references, but it lacks sufficient corresponding inline citations. Please help to improve this article by introducing more precise citations. (February 2015) (Learn how and when to remove this message) The neutrality of this article is disputed. Relevant discussion may be found on...

 

 

List of Canadian events in 2018 This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed.Find sources: 2018 in Canada – news · newspapers · books · scholar · JSTOR (September 2023) (Learn how and when to remove this message) ← 2017 2016 2015 2018 in Canada → 2019 2020 2021 Decades: 1990s 2000s 2010s 2020s See also: His...

Sporting event delegationAlgeria at the1968 Summer OlympicsIOC codeALG(AGL used at these Games)NOCAlgerian Olympic CommitteeWebsitewww.coa.dzin Mexico CityCompetitors3 in 2 sportsMedals Gold 0 Silver 0 Bronze 0 Total 0 Summer Olympics appearances (overview)1964196819721976198019841988199219962000200420082012201620202024Other related appearances France (1896–1960) Algeria competed at the 1968 Summer Olympics in Mexico City, Mexico. Boxing Main article: Boxing at the 1968 Summer Olympics...

 

 

College football game2016 Dr. Pepper Big Ten Football Championship GameConference ChampionshipChampionship Game Logo Wisconsin Badgers Penn State Nittany Lions (10–2) (10–2) 31 38 Head coach: Paul Chryst Head coach: James Franklin APCoachesCFP 666 APCoachesCFP 887 1234 Total Wisconsin 141430 31 Penn State 771410 38 DateDecember 3, 2016Season2016StadiumLucas Oil StadiumLocationIndianapolis, INMVPTrace McSorley (PSU)FavoriteWisconsin by 3National anthemCombined bands of...

 

 

Refugee Camp in Ramallah and al-Bireh, State of PalestineJalazone CampRefugee CampArabic transcription(s) • Arabicمخيّم الجلزون • Latinal-Jalazun Camp (official)al-Jalazoun Camp (unofficial)View of Jalazone Camp from road coming from Jifna in 2009, Khaldun BsharaJalazone CampLocation of Jalazone Camp within PalestineCoordinates: 31°57′07.15″N 35°12′41.58″E / 31.9519861°N 35.2115500°E / 31.9519861; 35.2115500StateSta...

The Cat and the CanarySutradaraRadley MetzgerProduserRichard GordonSkenarioRadley MetzgerBerdasarkanThe Cat and the Canaryoleh John WillardPemeran Honor Blackman Michael Callan Edward Fox Wendy Hiller Olivia Hussey Wilfred Hyde-White Beatrix Lehmann Carol Lynley Daniel Massey Peter McEnery Penata musikSteven CaganSinematograferAlex ThomsonPenyuntingRoger HarrisonDistributorGrenadier FilmsTanggal rilis 16 November 1978 (1978-11-16) (Miami Film Festival)[1] Durasi98 minut...

 

 

Cet article est une ébauche concernant une localité anglaise. Vous pouvez partager vos connaissances en l’améliorant (comment ?) selon les recommandations des projets correspondants. Pour les articles homonymes, voir Corse (homonymie). CorseGéographiePays  Royaume-UniRégion Angleterre du Sud-OuestComté cérémonial GloucestershireComté non métropolitain Gloucestershire (d)District non métropolitain Forest of DeanCoordonnées 51° 56′ 09″ N, 2° 18...