Rank: 251152 based on 0 downloads (last 30 days) and 0 file submitted
photo

Matthew

E-mail

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Comments and Ratings by Matthew View all
Updated File Comments Rating
02 Jun 2014 fminsearchbnd, fminsearchcon Bound constrained optimization using fminsearch Author: John D'Errico

11 Feb 2014 MyFisher33 A very compact routine to compute Fisher's exact test on a 3x3 matrix Author: Giuseppe Cardillo

line 146: you must use "<=" not "<"

i.e., the line should read:

P=sum(np(np<=op));

(You want to sum across all probabilities that are less than or equal to the observed probability)

11 Feb 2014 MyFisher23 A very compact routine for Fisher's exact test on 2x3 contingency table Author: Giuseppe Cardillo

if you add the following lines:

% filter out bad stuff
bad_rows = logical(sum(Tables < 0,2));
Tables = Tables(~bad_rows,:);

at like, line 108 (immediately before calling "gammaln"), then it does not CRASH.

But just because it does not crash does not mean that it actually computes the correct numbers....

11 Feb 2014 MyFisher23 A very compact routine for Fisher's exact test on 2x3 contingency table Author: Giuseppe Cardillo

The following produces an error:

myfisher23([ 6 6 9 ; 7 7 9])

The error is:

Error using gammaln
Input must be nonnegative.
Error in myfisher23 (line 112)
zf=gammaln(Tables+1); %compute log(x!)

Contact us