Rank: 688 based on 102 downloads (last 30 days) and 5 files submitted
photo

Michael Boedigheimer

E-mail

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Files Posted by Michael View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
17 Jan 2012 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer statistics, biotech, genetics, hypergeometric, probability, fisher exact 56 5
01 Jan 2011 LinStats Statistical analysis (ANOVA,…) and plotting of fixed and mixed effects models using modern methods Author: Michael Boedigheimer statistics, gui, optimization, anova, mixed model, random effects 14 1
  • 4.0
4.0 | 2 ratings
13 Jul 2007 Screenshot mmvn_toolkit complete toolkit for generating, training, testing and viewing multidimensional gaussian mixtures Author: Michael Boedigheimer statistics, probability, em, gaussian mixture, normal density, likelihood 14 3
  • 4.0
4.0 | 1 rating
10 Jul 2007 Screenshot Clustering by Passing Messages Automated clustering through messaging Author: Michael Boedigheimer statistics, probability, clustering, affinity propagation 3 0
  • 4.0
4.0 | 1 rating
27 Dec 2006 Published MATLAB Files linstats 2006b linear multivariate statistics Author: Michael Boedigheimer statistics, probability, em anova manova anaco... 15 1
  • 5.0
5.0 | 3 ratings
Comments and Ratings by Michael View all
Updated File Comments Rating
17 Jan 2012 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer

Giuseppe
I am sorry you are having difficulty with the function. My function is very well tested and as far as I can tell works as described. The problem I am working on is detailed in the documentation of the function. I have hundreds of samples and 10s of thousands or more replicates. In the example you give there are many more samples than that. In your smallest example you have 2900. In that case solving for 1 replicate takes 3s on my computer, but so does solving 10,000 replicates.
y = unidrnd(2,2900,1)-1;
x = unidrnd(2, 2900, 1)-1;
Elapsed time is 2.984087 seconds.
>> x = unidrnd(2, 2900, 10000)-1;
>> tic; z = fexact(x,y); toc
Elapsed time is 2.947621 seconds.

I mean no disrespect to you or your many contributions. I just didn't see how your program can be used to solve the problem I just described.

16 Jun 2011 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer

fexact can use vector inputs and it will calculate contingency tables for you, or it can take the same input as Matlab's hygecdf. For your convenience, from fexact's help, here is a 2x2 contingency table, with a,b,c and d being integer counts
a c
b d

K = a+c;
N = a+b;
M = a+b+c+d

then use fexact( a,M,K,N)
enjoy

Comments and Ratings on Michael's Files View all
Updated File Comment by Comments Rating
17 Jan 2012 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer Boedigheimer, Michael

Giuseppe
I am sorry you are having difficulty with the function. My function is very well tested and as far as I can tell works as described. The problem I am working on is detailed in the documentation of the function. I have hundreds of samples and 10s of thousands or more replicates. In the example you give there are many more samples than that. In your smallest example you have 2900. In that case solving for 1 replicate takes 3s on my computer, but so does solving 10,000 replicates.
y = unidrnd(2,2900,1)-1;
x = unidrnd(2, 2900, 1)-1;
Elapsed time is 2.984087 seconds.
>> x = unidrnd(2, 2900, 10000)-1;
>> tic; z = fexact(x,y); toc
Elapsed time is 2.947621 seconds.

I mean no disrespect to you or your many contributions. I just didn't see how your program can be used to solve the problem I just described.

17 Jan 2012 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer Cardillo, Giuseppe

I compared your function with the mine using this matrix:
x=[7 12; 8 2].*1000000

Using Myfisher22(x), the function written by me, the result was:
Elapsed time is 5.715080 seconds.

Using your
fexact(x(1),sum(x(:)),x(1)+x(3),x(1)+x(2)) the results were:

??? Maximum variable size allowed by the program is exceeded.

Error in ==> fexact>tri2sqind at 325
    k = (1:max_k)';
Error in ==> fexact>getLookup at 211
[k n ind] = tri2sqind(M);
Error in ==> fexact at 142
    P = getLookup( M,N,tail);

Same results reducing the complexity to
x=[7 12; 8 2].*100000 and
x=[7 12; 8 2].*10000

When I tried on x=[7 12; 8 2].*1000 the pc looped and after 15 minutes I switched it off.

Finally I tried it on x=[7 12; 8 2].*100
Elapsed time is 6.019058 seconds; using Myfisher22 on this "simple" matrix
Elapsed time is 0.008264 seconds.

So before to write "Other implementations on the file exchange are reportedly buggy and are far too slow for problems I'm working on."
I think that you should test deeper your function.

Regards

07 Nov 2011 LinStats Statistical analysis (ANOVA,…) and plotting of fixed and mixed effects models using modern methods Author: Michael Boedigheimer Steven

Thank you for building this!

16 Jun 2011 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer Boedigheimer, Michael

fexact can use vector inputs and it will calculate contingency tables for you, or it can take the same input as Matlab's hygecdf. For your convenience, from fexact's help, here is a 2x2 contingency table, with a,b,c and d being integer counts
a c
b d

K = a+c;
N = a+b;
M = a+b+c+d

then use fexact( a,M,K,N)
enjoy

16 Jun 2011 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer Tobias

I second James Herman's comment. It would be great if someone could explain how to input a contingency table into this function.

Top Tags Applied by Michael
statistics, probability, affinity propagation, anova, biotech
Files Tagged by Michael View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
17 Jan 2012 Fisher’s Exact Test Hypergeometric cumulative distribution (left, right and two-tailed) including permutation testing. Author: Michael Boedigheimer statistics, biotech, genetics, hypergeometric, probability, fisher exact 56 5
01 Jan 2011 LinStats Statistical analysis (ANOVA,…) and plotting of fixed and mixed effects models using modern methods Author: Michael Boedigheimer statistics, gui, optimization, anova, mixed model, random effects 14 1
  • 4.0
4.0 | 2 ratings
13 Jul 2007 Screenshot mmvn_toolkit complete toolkit for generating, training, testing and viewing multidimensional gaussian mixtures Author: Michael Boedigheimer statistics, probability, em, gaussian mixture, normal density, likelihood 14 3
  • 4.0
4.0 | 1 rating
10 Jul 2007 Screenshot Clustering by Passing Messages Automated clustering through messaging Author: Michael Boedigheimer statistics, probability, clustering, affinity propagation 3 0
  • 4.0
4.0 | 1 rating
27 Dec 2006 Published MATLAB Files linstats 2006b linear multivariate statistics Author: Michael Boedigheimer statistics, probability, em anova manova anaco... 15 1
  • 5.0
5.0 | 3 ratings

Contact us at files@mathworks.com