input/output 使用 Octave GNU 访问文件
input/output file access with Octave GNU
我想将 mxArray
保存到 Octave .mat
文件中。
我在 Octave 中用 c++ 创建了一个 mex 函数,它读取二进制文件并将数据填充到 mxArray
。我想用 Octave 可视化这些数据。我想以 Octave 格式或 .mat
格式保存数据。
用Matlab,有matOpen()
打开文件,matClose()
关闭文件,matPutVariable()
写入数据到文件。 Octave 中这些 Matlab 函数的等效函数是什么?
编辑:
正如此(已编辑)答案的评论中所提议的那样:https://github.com/tbeu/matio 就是为此目的而设计的。
在编辑提议中,OP 说:
this solved the issue. matio seems not optimized as Matlab library though.
我想将 mxArray
保存到 Octave .mat
文件中。
我在 Octave 中用 c++ 创建了一个 mex 函数,它读取二进制文件并将数据填充到 mxArray
。我想用 Octave 可视化这些数据。我想以 Octave 格式或 .mat
格式保存数据。
用Matlab,有matOpen()
打开文件,matClose()
关闭文件,matPutVariable()
写入数据到文件。 Octave 中这些 Matlab 函数的等效函数是什么?
编辑:
正如此(已编辑)答案的评论中所提议的那样:https://github.com/tbeu/matio 就是为此目的而设计的。 在编辑提议中,OP 说:
this solved the issue. matio seems not optimized as Matlab library though.