A lot of work on using the Pattern Recognition Toolbox.