making a big dat(binary) file

조회 수: 4(최근 30일)
PEDRO FELICIANO
PEDRO FELICIANO 2020년 4월 12일
댓글: PEDRO FELICIANO 2020년 4월 14일
Hello people, I need to make a single binary file containing several sessions of electrophysiological recordings. The dat file needs to be a matrix where every single row is a single channel and columns represent samples. My old Matlab code did the dat file by creating a matrix(ch x samp) first, writing down the matrix into the dat file, cleaning up memory and starting with the next session. It works well but, somedays I have sessions where the data matrix is bigger than the memory capacity of my machine. Making Matlab running out of memory.
Been able to write down channel by channel into the dat file I think it could work. Did someone know if that is possible? Inserting a row by row into the dat file using a loop?
It is my understanding that fwrite writes in column order. Is it possible to have a code that writes in row order?
Thanks,
  댓글 수: 2
PEDRO FELICIANO
PEDRO FELICIANO 2020년 4월 14일
I'll try that. Thanks.

댓글을 달려면 로그인하십시오.

답변(1개)

Rajani Mishra
Rajani Mishra 2020년 4월 14일
As mentioned in previous comment you can take transpose of array x and thus column by column data can be written.
  댓글 수: 1
PEDRO FELICIANO
PEDRO FELICIANO 2020년 4월 14일
I'll try that, thanks.

댓글을 달려면 로그인하십시오.

제품


릴리스

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by