RestoreDiscClass
RestoreDiscClass changes the class of the data in a MAT file (v6)
Example:
filename=RestoreDiscClass(FILENAME, VARNAME)
FILENAME: The target file. Must be a v6 MAT-file
VARNAME: string with the variable name
VARNAME must be a standard matrix (numeric (including complex), logical
or char) but may not be sparse. RestoreDiscClass works with both real and
complex variables
The MATLAB builin SAVE command casts data to the smallest class possible
without causing loss of data. LOAD then casts back to the original class.
RestoreDiscClass casts the data on disc to the original class. The target
variable must be the final variable in the MAT-file i.e. it must be at
the end of the file
RestoreDiscClass should be called before using any of the AppendXXXXX
functions to ensure that adequate bytes have been set aside to store
the appended data without loss.
FILENAME is returned by RestoreDiscClass prefixed with full path details.
This can be used to avoid confusion if multiple files with the same name
occur and no path is specified expicitly (although this would normally
only cause problems if there are MAT files in the \private folder of the
MAT-utilities)
__________________________________________________________________________
This program is distributed without any warranty,
without even the implied warranty of fitness for a particular purpose.
__________________________________________________________________________
Author: Malcolm Lidierth 11/06
Copyright © The Author & King's College London 2006
__________________________________________________________________________
Revisions: 04.11.07 Reposition code for no change: now faster