[英]input/output file access with Octave GNU
I want to save mxArray
to an Octave .mat
file. 我想将mxArray
保存到Octave .mat
文件。
I created a mex function with c++ in Octave that reads binary files and populate the data to an mxArray
. 我在Octave中使用c ++创建了一个mex函数,该函数读取二进制文件并将数据填充到mxArray
。 I would like to visualize these data with Octave. 我想用Octave可视化这些数据。 I would like to save the data in an Octave format or .mat
format. 我想以Octave格式或.mat
格式保存数据。 with Matlab , there are matOpen()
to open a file, matClose()
to close the file, and matPutVariable()
to write the data to the file. 使用Matlab时 ,有matOpen()
可以打开文件,有matClose()
可以关闭文件,还有matPutVariable()
可以将数据写入文件。 what are the equivalent functions in Octave the these Matlab functions? 这些Matlab函数中Octave的等效函数是什么?
As proposed in the comments of this (edited) answer : https://github.com/tbeu/matio is designed for that purpose. 正如此(经编辑)答案的评论中所建议的那样: https : //github.com/tbeu/matio是为此目的而设计的。 In an edit proposition the OP said : OP在一个编辑建议中说:
this solved the issue. 这解决了问题。 matio seems not optimized as Matlab library though. matio似乎没有作为Matlab库进行优化。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.