The MatIO namespace

Read and write mat files.

Function List

ExportMatFile (matrix Matrix, filename string, varname string)
Writes the given Matrix object to a *.mat file. (Returns a boolean object.)
ExportMatFile (matrix ComplexMatrix, filename string, varname string)
Writes the given ComplexMatrix object to a *.mat file. (Returns a boolean object.)
ExportMatFile (table table, filename string, varname string)
Writes the given table structure to a *.mat file. (Returns a boolean object.)
ExportMatFile (dataset DataSet, filename string, varname string)
Writes the given DataSet object to a *.mat file. (Returns a boolean object.)
GetNames (filename string)
Lists the variables in a *.mat file that can be read into a DataSet object. (Returns a List of string object.)
ReadMatFile (filename string)
Reads all data from a *.mat file in its original structure. (Returns a table object.)
ReadMatFile (filename string, name string)
Reads a specific variable from *.mat file. (Returns a DataSet object.)
ReadMatFileStructure (filename string)
Reads the structure of a *.mat file without importing DataSet information. (Returns a table object.)
ReadMatFileToTable (filename string, name string)
Reads a specific variable from *.mat file. (Returns a table object.)

Function Details

ExportMatFile (matrix Matrix, filename string, varname string)
Writes the given Matrix object to a *.mat file.
Input Parameters
matrix(Matrix)
The Matrix.
filename(string)
Filename of the *.mat file.
varname(string)
The name of the variable to export.
Return
boolean
Boolean to indicate if it was successful.
ExportMatFile (matrix ComplexMatrix, filename string, varname string)
Writes the given ComplexMatrix object to a *.mat file.
Input Parameters
matrix(ComplexMatrix)
The ComplexMatrix.
filename(string)
Filename of the *.mat file.
varname(string)
The name of the variable to export.
Return
boolean
Boolean to indicate if it was successful.
ExportMatFile (table table, filename string, varname string)
Writes the given table structure to a *.mat file.
Input Parameters
table(table)
The Lua table.
filename(string)
Filename of the *.mat file.
varname(string)
The name of the variable to export.
Return
boolean
Boolean to indicate if it was successful.
ExportMatFile (dataset DataSet, filename string, varname string)
Writes the given DataSet object to a *.mat file.
Input Parameters
dataset(DataSet)
The DataSet.
filename(string)
Filename of the *.mat file.
varname(string)
The name of the variable to export.
Return
boolean
Boolean to indicate if it was successful.
GetNames (filename string)
Lists the variables in a *.mat file that can be read into a DataSet object.
Input Parameters
filename(string)
Filename of the *.mat file.
Return
List of string
Returns a List of string.
ReadMatFile (filename string)
Reads all data from a *.mat file in its original structure.
Input Parameters
filename(string)
Filename of the *.mat file.
Return
table
Returns a table object.
ReadMatFile (filename string, name string)
Reads a specific variable from *.mat file.
Input Parameters
filename(string)
Filename of the *.mat file.
name(string)
The name of the variable.
Return
DataSet
Returns a DataSet object.
ReadMatFileStructure (filename string)
Reads the structure of a *.mat file without importing DataSet information.
Input Parameters
filename(string)
Filename of the *.mat file.
Return
table
Returns a table object.
ReadMatFileToTable (filename string, name string)
Reads a specific variable from *.mat file.
Input Parameters
filename(string)
Filename of the *.mat file.
name(string)
The name of the variable.
Return
table
Returns a Lua table.