Code covered by the BSD License  

Highlights from
MyFisher33

Be the first to rate this file! 3 Downloads (last 30 days) File Size: 3.02 KB File ID: #15482

MyFisher33

by Giuseppe Cardillo

 

03 Jul 2007 (Updated 23 Dec 2009)

A very compact routine to compute Fisher's exact test on a 3x3 matrix

| Watch this File

File Information
Description

Fisher's exact test of 3x3 contingency tables permits calculation of precise probabilities in situation where, as a consequence of small cell frequencies, the much more rapid normal approximation and chi-square calculations are liable to be inaccurate. The Fisher's exact test involves the computations of several factorials to obtain the probability of the observed and each of the more extreme tables. Factorials growth quickly, so it's necessary use logarithms of factorials. In Matlab this is very easy using the Gammaln function. The function uses preallocation and vectorization to speed-up the computations. Actually, the function also computes the mid-P correction to make the test less conservative.

You can visit my homepage http://home.tele2.it/cardillo
My profile on XING http://www.xing.com/go/invita/13675097
My profile on LinkedIN http://it.linkedin.com/in/giuseppecardillo

MATLAB release MATLAB 7.3 (R2006b)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Please login to add a comment or rating.
Updates
01 May 2008

waitbar added

27 Jun 2008

6-fold speed up using preallocation

02 Jul 2008

Speeding up using preallocation and gammaln calculation

12 Nov 2008

Changes in help section

26 Nov 2008

Improvements in table enumeration

23 Oct 2009

Actually, the function also computes the mid-P correction to make the test less conservative.

23 Dec 2009

Changes in description

Tag Activity for this File
Tag Applied By Date/Time
statistics Giuseppe Cardillo 22 Oct 2008 09:18:03
probability Giuseppe Cardillo 22 Oct 2008 09:18:03
fisher exact test 3x3 matrix Giuseppe Cardillo 22 Oct 2008 09:18:03
statistics Cristina McIntire 12 Nov 2008 14:03:03
probability Cristina McIntire 12 Nov 2008 14:03:03
test Cristina McIntire 05 Dec 2008 14:40:11
probability Dmitry 03 Oct 2009 08:46:53
fisher exact test 3x3 matrix Manuele 13 Sep 2011 16:13:02
probability Manuele 13 Sep 2011 16:13:06
statistics Manuele 13 Sep 2011 16:13:09

Contact us at files@mathworks.com