MatlabTools.py -

Author:Andreas Heger
Release:$Id$
Date:December 09, 2013
Tags:Python

Code

MatlabTools.WriteMatrix(matrix, outfile=<open file '<stdout>', mode 'w' at 0x7f1ccf94d150>, separator='\t', format='%f', row_headers=None, col_headers=None)

write matrix to stream.

MatlabTools.ReadMatrix(file, separator='\t', numeric_type=<type 'float'>, take='all', headers=False)

read a matrix. There probably is a routine for this in Numpy, which I haven’t found yet.

MatlabTools.ReadSparseMatrix(filename, separator='\t', numeric_type=<type 'float'>, is_symmetric=None)

read sparse matrix.

MatlabTools.ReadBinarySparseMatrix(filename, separator='\t', numeric_type=<type 'float'>, is_symmetric=None)

read sparse matrix.

MatlabTools.readMatrix(infile, format='full', separator='\t', numeric_type=<type 'float'>, take='all', headers=True, missing=None)

read a matrix from file ane return a numpy matrix.

formats accepted are: * full * sparse * phylip

MatlabTools.writeMatrix(outfile, matrix, format='full', separator='\t', value_format='%f', row_headers=None, col_headers=None)

write matrix to stream.

Table Of Contents

Previous topic

<no title>

Next topic

<no title>

This Page