mlab Package

mlab Package

Provides python functions which are useful for interacting with MATLAB by using the mlabwrap library.

To use MATLAB functions directly, see cobra.matlab

mlab Module

cobra.mlab.mlab.cobra_model_object_to_cobra_matlab_struct(cobra_model)[source]

This function converts all of the object values to the corresponding model fields to update the mlab model.

cobra.mlab.mlab.init_matlab_toolbox(matlab_cobra_path=None)[source]

initialize the matlab cobra toolbox, and load its functions into mlab’s namespace (very useful for ipython tab completion)

matlab_cobra_path: the path to the directory containing the MATLAB cobra installation. Using the default None will attempt to find the toolbox in the MATLAB path

cobra.mlab.mlab.matlab_cell_to_python_list(the_cell)[source]
cobra.mlab.mlab.matlab_cobra_struct_to_python_cobra_object(matlab_struct)[source]

Converts a COBRA toolbox 2.0 struct into a cobra.Model object using the mlabwrap matlab proxy

cobra.mlab.mlab.matlab_logical_to_python_logical(the_logical)[source]
cobra.mlab.mlab.matlab_sparse_to_numpy_array(matlab_sparse_matrix)[source]
cobra.mlab.mlab.matlab_sparse_to_scipy_sparse(matlab_sparse_matrix)[source]
cobra.mlab.mlab.numpy_array_to_mlab_sparse(numpy_array)[source]

A more efficient method is needed for when the matrix is so big that making a dense version is a waste of computer effort.

cobra.mlab.mlab.python_list_to_matlab_cell(the_list, transpose=False)[source]
cobra.mlab.mlab.scipy_sparse_to_mlab_sparse(scipy_sparse_matrix)[source]

A more efficient method is needed for when the matrix is so big that making a dense version is a waste of computer effort.

Table Of Contents

Previous topic

manipulation Package

Next topic

solvers Package

This Page