modifying matlab command to work with new version of matlab