Date: Aug 16, 2011 5:15 PM
Subject: read in matrix from .dat file
I have been looking around the newsreader as well as other search engines for an answer to a problem I'm having, but haven't had any luck.
I have a camera that records data as a .sif file, and exports it as a .dat file. The video has a resolution of 512x512, is 600 frames in length, and the file size is 300MB. It may be exporting the video as a 307200x514 array (it adds a column of padding to both sides of the array, and stacks the frames together as rows ), but I'm not sure as I cant get the file open. It should be a space delimited file containing only numbers representing intensities on the camera, no text. My question is how to read the .dat file into matlab as an array.
I have tried:
A = fread('new02z.dat')
A = fopen('new02z.dat');
A = fopen('new02z.dat','r')
fid = ('new02z.dat')
A = fread(fid, [307200,514]);
A = textread('new02z.dat');
A = dlmread('new02z.dat',' ');
A = dlmread('new02z.dat',' ',0,0);
and the import data wizard.
all either imported a single digit, or returned error messages to which I have not found a solution for.
I am running 7.11.0 R2010b if that helps.