MATLAB Application Program Interface Reference Help Desk

matPutFull

Purpose

Writes full mxArrays into MAT-files

Fortran Syntax

Arguments

mfp

Pointer to MAT-file information.

m

Row dimension.

n

Column dimension.

name

Name of mxArray to write to MAT-file.

pi

Pointer to imaginary part.

pr

Pointer to real part.

Description

Most MATLAB applications work only with full (non-sparse) mxArrays. This routine provides an easy way to write a full mxArray into a MAT-file. It offers an alternative to matPutMatrix, which does not require use of the mxArray structure.

matPutFull writes the mxArray with dimensions m-by-n, real data pr, and imaginary data pi onto the MAT-file mfp with the specified name.

If the mxArray does not exist on the MAT-file, it is appended to the end. If an mxArray with the same name already exists in the file, the existing mxArray is replaced with the new mxArray by rewriting the file.

Examples

Read the mxArray A from one MAT-file and write it out to another

Write a simple real mxArray into a MAT-file. Name the mxArray A and the MAT-file foo.mat.

To test, run the second example; then go to MATLAB and enter:

Note: Fortran MAT-file routines are not available on Windows.



[ Previous | Help Desk | Next ]