LinStats is a collection of classes, functions and data that are useful for representing, solving and analyzing linear statistical models. LinStats has been updated to use a new object based approach to support incremental model-building and more sophisticated analysis.
Notably this is the first Matlab statistical package that can handle ANOVA and Variance Components models with fixed and random effects using Restricted Estimated Maximum Likelihood (REML) including the modern corrections for small sample size. This allows improved estimates for both fixed (Best linear unbiased estimates) and random terms (Best linear unbiased predictors).
Many statistical analysis including ANOVA involve random factors which poses challenging problems. Old solutions used approximations that were required before the advent of computers. Modern solutions use Restricted Estimated Maximum Likelihood. More recent enhancements and refinements include corrections for small sample size (Kenward and Roger) and take into account the uncertainty that parameter estimates have on variance estimates (Harville and Kackar).
This approach is becoming more common but the calculations are complex and this has slowed implementation. Matlab and R, for example, do not support this. I have only seen it in Professional statistics programs like SAS/JMP. Now, for the first time, Matlab Stats users don't need to take a backseat to users of those languages (at least in terms of mixed model analysis of linear models).
Fixed effects analysis outputs have been validated using National Institute of Standards and Technology Standards Technology Reference most difficult datasets (included with Linstats). Random effects outputs have been checked against results produced by SAS/JMP.
Please see zip file for the Word document containing the most complete documentation available.
Looks like there was a pathdef error in my installation and I'd lost a link to optimset. Test_linstats output below.
Thanks for freeing me from SAS!!!
passed: ArgParser
passed: Pmat standard ops
Warning: Colon operands must be real scalars.
> In test_dmat at 4
In test_linstats at 4
passed: Dmat
passed: BDmat
passed: lsestimates
passed: mixed models
passed: fixed effects model
passed: fixed effects model, no intercept
passed: 2-way anacova (separate lines)
Warning: The RandStream.getDefaultStream static method will be removed in a
future release. Use RandStream.getGlobalStream instead.
> In RandStream.RandStream>RandStream.getDefaultStream at 460
In test_model at 121
In test_linstats at 8
passed: 2-way anacova (separate lines), multiple response
passed: mixed effects, clinical example
passed: mixed effects, unbalanced clinical example
I've just installed this with R2011a and have run test_linstats which has thrown up a number of "Cell contents reference from a non-cell array object" errors.