查看“︁費雪正確概率檢定”︁的源代码
←
費雪正確概率檢定
跳转到导航
跳转到搜索
因为以下原因,您没有权限编辑该页面:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
{{noteTA |1=zh-hans:罗纳德·艾尔默·费希尔;zh-tw:羅納德·愛爾默·費雪;zh-hk:羅納德·愛爾默·費沙; |2=zh-hans:艾尔默;zh-hant:愛爾默; |3=zh-hans:费希尔;zh-tw:費雪;zh-hk:費沙; |4=zh-cn:零假设;zh-tw:虛無假說 |5=zh-cn:检验;zh-tw:檢定 |6=zh-cn:水平;zh-tw:水準 |G1=Math }} '''費雪正確概率檢定'''(英文:Fisher's exact test),或稱'''費雪精確檢定''',是[[統計學]]中的一種[[假說檢定]],用於檢驗[[列聯表]]的[[顯著性差異]],由[[羅納德·愛爾默·費雪]]於1935年所創。<ref>{{Cite journal |last=Fisher |first=R. A. |date=1922-01 |title=On the Interpretation of χ<sup>2</sup> from Contingency Tables, and the Calculation of P |url=https://www.jstor.org/stable/2340521?origin=crossref |journal=Journal of the Royal Statistical Society |volume=85 |issue=1 |doi=10.2307/2340521 |access-date=2022-12-22 |archive-date=2023-07-21 |archive-url=https://web.archive.org/web/20230721231037/https://www.jstor.org/stable/2340521?origin=crossref |dead-url=no }}</ref><ref>{{Cite book|edition=14th, rev. and enl|title=Statistical methods for research workers.|url=https://www.worldcat.org/oclc/135627|publisher=Hafner Pub. Co|date=1970|location=Darien, Conn.,|isbn=0-05-002170-2|oclc=135627|first=Ronald Aylmer, Sir|last=Fisher}}</ref><ref name = "agresti">{{Cite journal |last=Agresti |first=Alan |date=1992-02-01 |title=A Survey of Exact Inference for Contingency Tables |url=https://projecteuclid.org/journals/statistical-science/volume-7/issue-1/A-Survey-of-Exact-Inference-for-Contingency-Tables/10.1214/ss/1177011454.full |journal=Statistical Science |volume=7 |issue=1 |doi=10.1214/ss/1177011454 |issn=0883-4237 |access-date=2022-12-22 |archive-date=2023-05-30 |archive-url=https://web.archive.org/web/20230530133148/https://www.projecteuclid.org/journals/statistical-science/volume-7/issue-1/A-Survey-of-Exact-Inference-for-Contingency-Tables/10.1214/ss/1177011454.full |dead-url=no }}</ref>實務中,該方法常用於[[樣本 (統計學)|樣本數]]較小的情況,但其實不限於小樣本情況。它屬於一種{{le|精確檢定|Exact test}},也就是其[[p值]]可以由[[虛無假說]]的分布實際計算而不是藉由足夠的樣本數逼近一個特定的機率分布。 據說,費雪根據{{Link-en|缪丽·布里斯托尔|Muriel Bristol}}女士聲稱能夠區別奶茶是先加了茶還是牛奶而設計了這項檢定。他在[[女士品茶]]實驗中亦實作了這項檢定。<ref name=newman>{{Cite book|title=The world of mathematics|chapter=Mathematics of a Lady Tasting Tea|url=https://www.worldcat.org/oclc/43555029|publisher=Dover Publications|date=2000|location=Mineola, N.Y.|isbn=978-0-486-41153-8|oclc=43555029|first=James R.|last=Newman|access-date=2022-12-22|archive-date=2022-05-05|archive-url=https://web.archive.org/web/20220505152045/https://www.worldcat.org/title/world-of-mathematics/oclc/43555029|dead-url=no}}</ref> == 目的與使用情境 == [[File:Nice Cup of Tea.jpg|thumb|受測者是否能夠區別沖泡完成的奶茶是先加茶還是先加牛奶?]] 此檢定在考驗兩種分類結果所產生的[[分类变量|類別型變數]]很有用;它用於檢查兩種分類結果之間的關聯(偶然性)是否[[顯著性差異|顯著]]。在費雪的原始例題中,一個分類結果是奶茶實際上的沖泡方式(先加牛奶還是茶),另一個分類標準是{{Link-en|缪丽·布里斯托尔|Muriel Bristol}}認定的沖泡方式,並使用本方法檢驗這兩種分類結果是否具有關聯(受測者是否真的可以分辨出先倒入的是牛奶還是茶)。如同[[女士品茶]]實驗,此檢定大多數使用於2 × 2列聯表(如下所述)。最終求得的[[p值]]是基於列聯表邊際是固定的,也就是受測者明確知曉八杯茶中有四杯先加牛奶,因此必然只會挑出四杯。這導致表格單元格中數字在[[獨立 (機率論)|獨立性]][[虛無假說]]下服從[[超幾何分佈]]。 若樣本數較大,一般使用[[卡方檢定]]或{{le|G檢定|G-test}},其統計量近似於[[卡方分布]]。在樣本數較小或是表格中次數差異很大的情況,這樣的大樣本近似方法不適用。通常可以預先檢查表格中各細格的[[期望值]]是否皆大於5(或是只有一格小於10)以決定可否使用基於卡方分布的大樣本近似方法,雖然這樣的預先檢查已被認定為過度保守。<ref name="Larntz1978">{{Cite journal |last=Larntz |first=Kinley |date=1978-06 |title=Small-Sample Comparisons of Exact Levels for Chi-Squared Goodness-of-Fit Statistics |url=http://www.tandfonline.com/doi/abs/10.1080/01621459.1978.10481567 |journal=Journal of the American Statistical Association |language=en |volume=73 |issue=362 |doi=10.1080/01621459.1978.10481567 |issn=0162-1459 |access-date=2022-12-22 |archive-date=2023-01-13 |archive-url=https://web.archive.org/web/20230113064155/https://www.tandfonline.com/doi/abs/10.1080/01621459.1978.10481567 |dead-url=no }}</ref>事實上,卡方近似方法的p值在過小、稀疏的或不平衡的數據與精確檢定的p值可能南轅北轍而導致相反結論。<ref name="Mehta1984">{{Cite journal |last=Mehta |first=Cyrus R. |last2=Patel |first2=Nitin R. |last3=Tsiatis |first3=Anastasios A. |date=1984-09 |title=Exact Significance Testing to Establish Treatment Equivalence with Ordered Categorical Data |url=https://www.jstor.org/stable/2530927?origin=crossref |journal=Biometrics |volume=40 |issue=3 |doi=10.2307/2530927 |access-date=2022-12-22 |archive-date=2022-12-21 |archive-url=https://web.archive.org/web/20221221081040/https://www.jstor.org/stable/2530927?origin=crossref |dead-url=no }}</ref><ref name="Mehta1995">{{Cite book|title=SPSS exact tests 6.1 for Windows|url=https://www.worldcat.org/oclc/34436454|publisher=SPSS Inc|date=1995|location=Chicago, Ill.|isbn=0-13-450891-2|oclc=34436454|first=Nitin R.|last=Patel|last2=SPSS Inc}}</ref>相比之下,費雪精確檢定,正如其名稱所述,只要實驗過程保持行和列總和固定不變,它就是精確的,因此無論樣本特徵如何都可以使用。費雪的方法雖然使用於大樣本或平衡良好的表格會使計算變得困難,但幸運的是,這些正是卡方檢定適合的條件。 此檢定在2 × 2列聯表的情況下可以用手計算。然而,此方法其實可以擴展到''m'' × ''n''聯表的情況,<ref>{{Cite journal |last=Mehta |first=Cyrus R. |last2=Patel |first2=Nitin R. |date=1983-06 |title=A Network Algorithm for Performing Fisher's Exact Test in ''r'' × ''c'' Contingency Tables |url=https://www.jstor.org/stable/2288652?origin=crossref |journal=Journal of the American Statistical Association |volume=78 |issue=382 |doi=10.2307/2288652 |access-date=2022-12-22 |archive-date=2022-12-21 |archive-url=https://web.archive.org/web/20221221081543/https://www.jstor.org/stable/2288652?origin=crossref |dead-url=no }}</ref>但計算並不容易,可改用統計軟體計算(其中有些使用[[蒙特卡羅方法]]來獲得p值的近似值)。<ref>{{Cite journal |last=Mehta |first=Cyrus R. |last2=Patel |first2=Nitin R. |date=1986-06 |title=ALGORITHM 643: FEXACT: a FORTRAN subroutine for Fisher's exact test on unordered ''r''×''c'' contingency tables |url=https://dl.acm.org/doi/10.1145/6497.214326 |journal=ACM Transactions on Mathematical Software |language=en |volume=12 |issue=2 |doi=10.1145/6497.214326 |issn=0098-3500 |access-date=2022-12-22 |archive-date=2023-07-21 |archive-url=https://web.archive.org/web/20230721230915/https://dl.acm.org/doi/10.1145/6497.214326 |dead-url=no }}</ref> 此檢定還可用於量化兩組之間的「重疊程度」。例如,在統計[[遺傳學]]的{{le|富集分析|Gene set enrichment analysis}}中,可以為特定的表型加註一組基因(A)。使用者可以測試某些感興趣的基因組(B)與基因組A的重疊程度。在這種情況下,可以歸納成一個2 × 2列聯表以表示以下情況的次數: # 同時存在於A基因組與B基因組的基因 # 僅存在於A的基因 # 僅存在於B的基因 # 同時不存在於A與B的基因 該測試的[[虛無假設]]是任一基因組的基因都來自更廣泛的基因集,再以費雪正確概率檢定檢驗是否顯著重疊。<ref>{{Cite journal |last=Mi |first=Huaiyu |last2=Muruganujan |first2=Anushya |last3=Casagrande |first3=John T |last4=Thomas |first4=Paul D |date=2013-08 |title=Large-scale gene function analysis with the PANTHER classification system |url=http://www.nature.com/articles/nprot.2013.092 |journal=Nature Protocols |language=en |volume=8 |issue=8 |doi=10.1038/nprot.2013.092 |issn=1754-2189 |pmc=6519453 |pmid=23868073 |access-date=2022-12-22 |archive-date=2022-11-05 |archive-url=https://web.archive.org/web/20221105114458/https://www.nature.com/articles/nprot.2013.092 |dead-url=no }}</ref> == 例題 == 以一群青少年樣本為例,一方面可以將樣本分為男性和女性,另一方面可以分為目前正在或尚未準備統計學考試。樣本中正在準備考試的女性多於男性,而目標是檢驗這項比例差異是否顯著。數據如下所示: {|class="wikitable" style="text-align:center;" |- ! ! 男性 ! 女性 |列總和 |- !scope="row" | 正在準備考試 |bgcolor="lightgray" | '''1''' ||bgcolor="lightgray" | '''9''' || ''10'' |- !scope="row" | 尚未準備考試 |bgcolor="lightgray" | '''11''' ||bgcolor="lightgray" | '''3''' || ''14'' |- | 欄總和 | ''12'' || ''12'' || ''24'' |} 這些數據顯示這24名青少年中有10名正在準備考試,並且這24名青少年中有12名是女性。若[[虛無假說]]設定為男性和女性的學習比例是相等的,則這10名準備考試的青少年的性別分佈是否不同於尚未準備考試者?更具體的說,如果隨機選擇10位青少年,則能夠抽出12位女性中的9位(或更多)女性而12名男性中只抽出1位(或更少)的機率是多少? 在進行檢驗之前介紹一些符號:以字母''a''、''b''、''c''和''d''表示各細格中的次數,將跨行和跨列的總計稱為邊際總計,並用''n''表示總和數。所以上述表格可寫成: {|class="wikitable" style="text-align:center;" |- ! ! 男性 ! 女性 |列總和 |- !scope="row" | 正在準備考試 |bgcolor="lightgray" | '''''a''''' ||bgcolor="lightgray" | '''''b''''' || ''a'' + ''b'' |- !scope="row" | 尚未準備考試 |bgcolor="lightgray" | '''''c''''' ||bgcolor="lightgray" | '''''d''''' || ''c'' + ''d'' |- | 欄總和 | ''a'' + ''c'' || ''b'' + ''d'' || ''a'' + ''b'' + ''c'' + ''d'' = ''n'' |} 費雪表明,以表格中列總和與欄總和皆被故定為條件,''a''呈[[超幾何分布]],其中''a'' + ''c''從''a''+''b''成功和''c''+''d''失敗的[[母體 (統計學)|母體]]中抽出。獲得這樣一組結果的機率由下式給出:<ref name = "agresti"/>{{rp|136}}<ref>{{cite mathworld|title=Fisher's Exact Test | urlname =FishersExactTest |access-date=2022-12-26}}</ref> :<math>p = \frac{ \displaystyle{{a+b}\choose{a}} \displaystyle{{c+d}\choose{c}} }{ \displaystyle{{n}\choose{a+c}} } = \frac{ \displaystyle{{a+b}\choose{b}} \displaystyle{{c+d}\choose{d}} }{ \displaystyle{{n}\choose{b+d}} } = \frac{(a+b)!~(c+d)!~(a+c)!~(b+d)!}{a!~~b!~~c!~~d!~~n!}</math> 其中<math> \tbinom nk </math>是[[二項式係數]],符號「!」表示[[階乘|階乘運算]]。我們可以這樣理解:若已知所有的邊際總和(即''a'' + ''b''、''c'' + ''d''、''a'' + ''c''和''b'' + ''d''),則只剩下一個[[自由度 (统计学)|自由度]],例如已知''a''則足以推導出其他數值。現在,<math>{\displaystyle p=p(a)}</math>是從包含''n''個元素的更大集合中抽出不放回地隨機選擇''a'' + ''c''個元素時抽出''a''元素,這正是超幾何分布的定義。由上述資料可得, :<math>p = { {\tbinom{10}{1}} {\tbinom{14}{11}} }/{ {\tbinom{24}{12}} } = \tfrac{10!~14!~12!~12!}{1!~9!~11!~3!~24!} \approx 0.001346076</math> 上面的公式給出了觀察這種特定數據排列的確切超幾何機率,其前提是男性和女性具有相同比例進行考試準備比例的[[虛無假說]]以及邊際總數為定值。換句話說,如果假設男性與女性準備考試的機率都是''p'',並且男性和女性都是獨立地被採樣,無論他們是否正在準備考試,那麼這個超幾何公式給出了在四個單元格中觀察次數''a''、''b''、''c''、''d''的[[條件機率]],其中的條件是已知的邊緣總數(也就是列與欄總數)。即使男性與女性以不同的機率抽出成為樣本(例如母體中性別比例不是1:1),這仍然是正確的。要求僅僅是兩個分類特徵(性別和是否準備考慮)互為[[獨立 (機率論)|獨立事件]]。例如,假設我們知道機率''P''和''Q''分別表示男性與女性的邊際比例,機率''p''與''q''分別表示有無準備考試的邊際比例,自然存在''P'' + ''Q'' = 1與''p'' + ''q'' = 1的事實,且性別和是否準備考慮互為[[獨立 (機率論)|獨立事件]],則上述資料各性別與是否準備考試的機率則分別為 * 已準備考試的男性機率:''PQ'' * 已準備考試的女性機率:''pQ'' * 未準備考試的男性機率:''Pq'' * 未準備考試的女性機率:''pq'' 之後,若計算給定邊緣條件的分佈,將可獲得上述的公式,其中''p''和''P''都不在式中。因此24名青少年任意排列到表的四個單元格中的確切機率是可以計算的。費雪表明,[[統計顯著性]]的計算只需要考慮邊際總和與觀測結果相同或更極端的情況即可。({{le|巴納德檢定|Barnard's test}}則放寬了對一組邊際總數的限制。)在該示例中,有11種排列方式與上述數據在相同的方向上更為極端,並可以簡化為1種組合(如下表): {|class="wikitable" style="text-align:center;" |- ! ! 男性 ! 女性 |列總和 |- !scope="row" | 正在準備考試 |bgcolor="lightgray" | '''0''' ||bgcolor="lightgray" | '''10''' || ''10'' |- !scope="row" | 尚未準備考試 |bgcolor="lightgray" | '''12''' ||bgcolor="lightgray" | '''2''' || ''14'' |- | 欄總和 | ''12'' || ''12'' || ''24'' |} 而發生這組資料的機率(在相同前提下)為 <math>{p = {\tbinom{10}{0}} {\tbinom{14}{12}} }/{ {\tbinom{24}{12}} } \approx 0.000033652</math> 若[[虛無假說]]為真可以得到{{le|單尾與雙尾檢定|One- and two-tailed tests|單尾檢定}}的p值,即目前資料及更極端的資料的機率總和,約等於0.001346076 + 0.000033652 = 0.001379728。在[[R語言]]環境下,這個值可以藉由<code>fisher.test(rbind(c(1,9),c(11,3)),alternative="less")$p.value</code>,或者在[[Python]]中使用<code>scipy.stats.fisher_exact(table=[[1,9],[11,3]], alternative="less")</code>獲取。該p值可以解釋為觀察數據(或任何更極端的表格)為[[虛無假說]](男性和女性準備考試的比例沒有差異)提供的證據總和。當p值越小,拒絕原假設的證據越多;因此例題中的數據強烈地表明男性和女性準備考試的可能性並不相同。 若考慮的是{{le|單尾與雙尾檢定|One- and two-tailed tests|雙尾檢定}},則需要額外考慮同樣極端但方向相反的表格,即對稱於目前資料方向的[[臨界區段|拒絕域]]。然而,此時「對稱處更極端的表格」並沒有唯一的定義。[[R語言]]提供的<code>fisher.test</code>函數採用的方法是對所有機率小於或等於目前資料概率的總和來計算p值,因此雙尾檢定的p值不一定是單尾檢定的二倍(特別是小樣本的情況),與其它具有對稱性的機率分布不同。 如上所述,太多數現代{{le|統計軟體列表|List of statistical software|統計軟體}}可以計算費雪精確檢定的顯著性,但此時可改以卡方分布的近似方法,<ref>{{Cite book|chapter=More on Dichotomous Variables|title=Biostatistical analysis : books a la carte edition.|url=https://www.worldcat.org/oclc/945142430|publisher=Prentice Hall|date=2010|location=[Place of publication not identified]|isbn=0-321-65686-5|oclc=945142430|first=Jerrold H.|last=Zar}}</ref>或是利用[[Γ函數]]或對數Γ函數。<ref>{{Cite journal |last=Zar |first=Jerrold H. |date=1987-07 |title=A fast and efficient algorithm for the Fisher exact test |url=http://link.springer.com/10.3758/BF03202590 |journal=Behavior Research Methods, Instruments, & Computers |language=en |volume=19 |issue=4 |doi=10.3758/BF03202590 |issn=0743-3808}}</ref>當樣本數很大或欄列數超過2時,計算費雪檢定是困難的,例如過程中面對過大的階乘。<ref>{{Cite journal |last=Warner |first=Pamela |date=2013-09-23 |title=Testing association with Fisher's Exact test |url=http://dx.doi.org/10.1136/jfprhc-2013-100747 |journal=Journal of Family Planning and Reproductive Health Care |volume=39 |issue=4 |doi=10.1136/jfprhc-2013-100747 |issn=1471-1893}}</ref>但隨[[個人電腦]]記算能力的進步,主流{{le|統計軟體列表|List of statistical software|統計軟體}}(諸如[[SPSS]]<ref>{{Cite book|title=IBM SPSS Exact Tests|chapter=Unordered R x C Contingency Tables|last=Mehta|first=Cyrus R.|publisher=IBM Corporation|year=2011|location=Armonk, NY|last2=Patel|first2=Nitin R.}}</ref>、[[統計分析系統|SAS]]<ref>{{Cite book|edition=3rd|title=Categorical data analysis using SAS|chapter=The 2 × 2 Table|url=https://www.worldcat.org/oclc/806311987|publisher=SAS Instute|date=2012|location=Cary, N.C.|isbn=978-1-61290-090-2|oclc=806311987|first=Charles S.|last=Davis|first2=Gary G.|last2=Koch|last3=SAS Institute}}</ref>、[[R語言]]<ref>{{Cite book|title=R: A Language and Environment for Statistical Computing|last=R Core Team|publisher=R Foundation for Statistical Computing|year=2022|location=Vienna, Austria|url=https://www.r-project.org/|access-date=2022-12-27|archive-date=2023-10-05|archive-url=https://web.archive.org/web/20231005133952/https://www.r-project.org/|dead-url=no}}</ref>、以及在[[Python]]語言環境使用[[SciPy]]工具包<ref>{{Cite web|last=The SciPy community|title=scipy.stats.fisher_exact|url=https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.fisher_exact.html|url-status=no|access-date=2022-12-27|website=SciPy documentation|language=en|archive-date=2023-06-10|archive-url=https://web.archive.org/web/20230610104043/https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.fisher_exact.html}}</ref>等)已納入費雪法的計算程式。 == 爭議 == 儘管費雪的檢定方法能精確地計算p值,但一些作者認為它是保守的,也就是檢定力較低。<ref name="Liddell-1976">{{Cite journal |last=Liddell |first=Douglas |date=1976-12 |title=Practical Tests of 2 × 2 Contingency Tables |url=https://www.jstor.org/stable/10.2307/2988087?origin=crossref |journal=The Statistician |volume=25 |issue=4 |doi=10.2307/2988087}}</ref><ref name="Berkson1978">{{Cite journal |last=Berkson |first=Joseph |date=1978-01 |title=In dispraise of the exact test |url=https://linkinghub.elsevier.com/retrieve/pii/0378375878900198 |journal=Journal of Statistical Planning and Inference |language=en |volume=2 |issue=1 |doi=10.1016/0378-3758(78)90019-8 |access-date=2022-12-22 |archive-date=2022-06-18 |archive-url=https://web.archive.org/web/20220618122751/https://linkinghub.elsevier.com/retrieve/pii/0378375878900198 |dead-url=no }}</ref><ref name="DAgostino1988">{{Cite journal |last=D'Agostino |first=Ralph B. |last2=Chase |first2=Warren |last3=Belanger |first3=Albert |date=1988-08 |title=The Appropriateness of Some Common Procedures for Testing the Equality of Two Independent Binomial Populations |url=https://www.jstor.org/stable/2685002?origin=crossref |journal=The American Statistician |volume=42 |issue=3 |doi=10.2307/2685002 |access-date=2022-12-22 |archive-date=2022-12-22 |archive-url=https://web.archive.org/web/20221222024149/https://www.jstor.org/stable/2685002?origin=crossref |dead-url=no }}</ref>當離散統計量的特性與選用固定的顯著性水準二者結合後可能發生這樣的問題。<ref name="Yates1984">{{Cite journal |last=Yates |first=F. |date=1984 |title=Test of Significance for 2 × 2 Contingency Tables |url=https://www.jstor.org/stable/10.2307/2981577?origin=crossref |journal=Journal of the Royal Statistical Society. Series A (General) |volume=147 |issue=3 |doi=10.2307/2981577}}</ref><ref name="Little1989">{{Cite journal |last=Little |first=Roderick J. A. |date=1989-11 |title=Testing the Equality of Two Independent Binomial Proportions |url=https://www.jstor.org/stable/2685390?origin=crossref |journal=The American Statistician |volume=43 |issue=4 |doi=10.2307/2685390 |access-date=2022-12-22 |archive-date=2022-12-22 |archive-url=https://web.archive.org/web/20221222024150/https://www.jstor.org/stable/2685390?origin=crossref |dead-url=no }}</ref>更準確地說,費雪檢定加總了在虛無假說成立時每種相同或更極端的表格之發生機率為p值,但由於所有表格的集合是離散的,可能不存在與實現情況相等的表格。若α<sub>e</sub>是小於5%的最大p值並存在於某些表格的集合,建議應預先測試有效的α<sub>e</sub>水準。對於小樣本量的清況,α<sub>e</sub>可能明顯低於5%。<ref name="Liddell-1976" /><ref name="Berkson1978" /><ref name="DAgostino1988" />雖然這種影響發生在任何離散統計數據中,但有人認為這一事實使費雪在邊際上的檢驗條件使問題更加複雜。<ref>{{cite web |first1=Cyrus R. |last1=Mehta |first2=Pralay |last2=Senchaudhuri |date=2003-09-04 |url=https://www.statsols.com/hubfs/Resources_/Comparing-Two-Binomials.pdf |title=Conditional versus unconditional exact tests for comparing two binomials |access-date=2009-11-20 |archive-date=2022-12-21 |archive-url=https://web.archive.org/web/20221221020424/https://www.statsols.com/hubfs/Resources_/Comparing-Two-Binomials.pdf |dead-url=no }}</ref>為了避免這個問題,許多作者在處理離散問題時不鼓勵使用固定的顯著性水準。<ref name="Yates1984" /><ref name="Little1989" /> 以表格邊緣為條件的決定也存在爭議。<ref name="Barnard1945a">{{Cite journal |last=Barnard |first=G. A. |date=1945-08 |title=A New Test for 2 × 2 Tables |url=https://www.nature.com/articles/156177a0 |journal=Nature |language=en |volume=156 |issue=3954 |doi=10.1038/156177a0 |issn=0028-0836 |access-date=2022-12-22 |archive-date=2022-12-22 |archive-url=https://web.archive.org/web/20221222025405/https://www.nature.com/articles/156177a0 |dead-url=no }}</ref><ref name="NatureDiscussion">{{Cite journal |last=Fisher |first=R. A. |date=1945-09 |title=A New Test for 2 × 2 Tables |url=https://www.nature.com/articles/156388a0 |journal=Nature |language=en |volume=156 |issue=3961 |doi=10.1038/156388a0 |issn=0028-0836 |access-date=2022-12-22 |archive-date=2023-07-21 |archive-url=https://web.archive.org/web/20230721192734/https://www.nature.com/articles/156388a0 |dead-url=no }}</ref>費雪檢定得出的p值來自以列邊際總和與欄邊際總和被固定。從這個意義上講,測試僅對條件分佈是精確的,而不是原始表格。在原始資料中,邊際總數可能因實驗而異而不適合使用費雪檢定。當邊際總和不固定時,可以考慮使用其他方法以獲得2 × 2表格的精確p值。例如,{{le|巴納德檢定|Barnard's test}}允許隨機的邊際總和。然而,一些作者(包括後來的巴納德本人)批評了巴納德基於此性質的檢定。<ref name="Yates1984" /><ref name="Little1989" /><ref name="NatureDiscussion" /><ref name="Yates1984" />他們認為邊際成功總數(即前先表格中的''a'' + ''b'')幾乎是[[輔助統計量]],<ref name="Little1989" />幾乎不包含有關測試屬性的信息。 從2 × 2表格中以邊際成功率為條件可能忽略了數據中關於未知{{le|勝算比|Odds ratio}}的一些信息。<ref name="Choi2015">{{Cite journal |last=Choi |first=Leena |last2=Blume |first2=Jeffrey D. |last3=Dupont |first3=William D. |date=2015-04-07 |editor-last=Olivier |editor-first=Jake |title=Elucidating the Foundations of Statistical Inference with 2 x 2 Tables |url=https://dx.plos.org/10.1371/journal.pone.0121263 |journal=PLOS ONE |language=en |volume=10 |issue=4 |doi=10.1371/journal.pone.0121263 |issn=1932-6203 |pmc=4388855 |pmid=25849515}}</ref>邊際總數(幾乎)是輔助統計量的論點意味著,用於推斷這個勝算比的適當似然函數應該以邊際成功率為條件。<ref name="Choi2015" />這種被忽略的信息對於推論的目的是否重要仍有爭論。<ref name="Choi2015" /> == 替代方法 == {{le|巴納德檢定|Barnard's test}}可用於代替費雪檢定,<ref>{{Cite journal |last=Lydersen |first=Stian |last2=Fagerland |first2=Morten W. |last3=Laake |first3=Petter |date=2009-03-30 |title=Recommended tests for association in 2×2 tables |url=https://onlinelibrary.wiley.com/doi/10.1002/sim.3531 |journal=Statistics in Medicine |language=en |volume=28 |issue=7 |doi=10.1002/sim.3531 |access-date=2022-12-22 |archive-date=2022-12-22 |archive-url=https://web.archive.org/web/20221222031450/https://onlinelibrary.wiley.com/doi/10.1002/sim.3531 |dead-url=no }}</ref>特別是在2 × 2表格的情況有更高的檢定力。<ref>{{cite journal | author = Berger R.L. | year = 1994 | title = Power comparison of exact unconditional tests for comparing two binomial proportions | journal = Institute of Statistics Mimeo Series No. 2266 | pages = 1–19 }}</ref>此外,{{le|博世路檢定|Boschloo's test}}是另一種精確檢定,亦比費雪檢定具有更高的檢定力。<ref name="Boschloo">{{Cite journal |last=Boschloo |first=R. D. |date=1970-03 |title=Raised conditional level of significance for the 2 × 2-table when testing the equality of two probabilities |url=https://onlinelibrary.wiley.com/doi/10.1111/j.1467-9574.1970.tb00104.x |journal=Statistica Neerlandica |language=en |volume=24 |issue=1 |doi=10.1111/j.1467-9574.1970.tb00104.x |issn=0039-0402 |access-date=2022-12-22 |archive-date=2022-12-22 |archive-url=https://web.archive.org/web/20221222032954/https://onlinelibrary.wiley.com/doi/10.1111/j.1467-9574.1970.tb00104.x |dead-url=no }}</ref> 對於階層式的類別資料,必須使用諸如{{le|CMH檢定|Cochran–Mantel–Haenszel statistics}}等考慮採樣階層的方法,而不是費雪檢定。 根據給定邊際成功率的勝算比的條件分布可以提出基於{{le|似然比檢定|Likelihood-ratio test}}的p值。<ref name="Choi2015" />此p值在推論上與[[常態分佈]]數據的經典檢定以及基於此條件[[似然函數]]的似然比和支持區間一致,並可在R語言上進行運算。<ref name="Choi2011">{{Cite web | last = Choi | first = Leena | year = 2011 | title = ProfileLikelihood: profile likelihood for a parameter in commonly used statistical models; 2011. R package version 1.1. | url = https://cran.r-project.org/web/packages/ProfileLikelihood/index.html | access-date = 2022-12-22 | archive-date = 2022-12-21 | archive-url = https://web.archive.org/web/20221221020430/https://cran.r-project.org/web/packages/ProfileLikelihood/index.html | dead-url = no }}</ref> ==相關條目== * {{le|巴納德檢定|Barnard's test}} * {{le|博世路檢定|Boschloo's test}} * {{le|勝算比|Odds ratio}} * [[列聯表]] * [[女士品茶]] ==參考文獻== {{Reflist|2}} == 外部連結 == * [http://www.langsrud.com/stat/fisher.htm 線上進行費雪檢定] {{Wayback|url=http://www.langsrud.com/stat/fisher.htm |date=20221221020447 }} * [https://web.archive.org/web/20170616070646/http://statcomp2.vanderbilt.edu:37212/ProfileLikelihood/ 2 × 2列聯表的概似比檢定] {{統計學}} [[Category:统计检验]]
该页面使用的模板:
Template:Cite book
(
查看源代码
)
Template:Cite journal
(
查看源代码
)
Template:Cite mathworld
(
查看源代码
)
Template:Cite web
(
查看源代码
)
Template:Le
(
查看源代码
)
Template:Link-en
(
查看源代码
)
Template:NoteTA
(
查看源代码
)
Template:Reflist
(
查看源代码
)
Template:Rp
(
查看源代码
)
Template:Wayback
(
查看源代码
)
Template:統計學
(
查看源代码
)
返回
費雪正確概率檢定
。
导航菜单
个人工具
登录
命名空间
页面
讨论
不转换
查看
阅读
查看源代码
查看历史
更多
搜索
导航
首页
最近更改
随机页面
MediaWiki帮助
特殊页面
工具
链入页面
相关更改
页面信息