tweaks to the Matlab file generation