added modified Nelder-Mead routine, refactored optimization support package
[CommonLispStat.git] / Examples / fstat.lsp
blob4b3a00bdf062532ecb15b7106a1b5333adda2085
1 (defun f-statistic (m1 m2)
3 Args: (m1 m2)
4 Computes the F statistic for testing model m1 within model m2."
5 (let ((ss1 (send m1 :sum-of-squares))
6 (df1 (send m1 :df))
7 (ss2 (send m2 :sum-of-squares))
8 (df2 (send m2 :df)))
9 (/ (/ (- ss1 ss2) (- df1 df2)) (/ ss2 df2))))