您的位置:首页 > 编程语言 > MATLAB

Matlab 的fwrite()函数和fread()函数

2010-11-15 22:17 369 查看
Matlab的fwrite()函数和fread()函数都是将从文件中读进来的数据按列顺序存放在矩阵中的。

A = FREAD(FID,SIZE) reads the number of elements specified by SIZE. Valid entries for SIZE are:

N read N elements into a column vector.

inf read to the end of the file.

[M,N] read elements to fill an M-by-N matrix, in column order.

N can be inf, but M can't.

 

COUNT = FWRITE(FID,A,PRECISION) writes the elements of matrix A to the specified file, translating MATLAB values to the specified precision.

The data are written in column order. COUNT is the number of elements successfully written.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: