Please tell me way to use both of these files and convert to csv. Spm stores a file in mat and dat format. Use writematrix to export matrix data as a csv file instead.