How do I set the 'ensure backward compatibility' option in the preferences for saving MAT files when using MATLAB 7.0.4 (R14SP2) with the 'no desktop' option?

2 views (last 30 days)
I would like to ensure backward compatibility (-v6) for saving MAT files. I can do this by going to File->Preferences and then checking 'ensure backward compatibility (-v6)' under General->MAT files tab. This ensures that all my MAT files are saved using the '-v6' option. However if I use MATLAB with the 'no desktop' option this capability is not available to me. I do not want to save each MAT file individually with the -'v6' option.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 27 Jun 2009
The ability to set the 'ensure backward compatibility' option in the preferences for saving MAT files when using the 'no desktop' option is not available in MATLAB.
To work around this issue execute the following code in the Command Window:
javaobj = com.mathworks.services.Prefs
javaMethod('setBooleanPref',javaobj,'SaveMatfileAsUnicode',0)
javaMethod('setBooleanPref',javaobj,'SaveMatfileCompressed',0)
Turning off compression and unicode, ensures backward compatibility of saved MAT files.

More Answers (0)

Categories

Find more on Software Development Tools in Help Center and File Exchange

Products


Release

R14SP2

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!