Importing .acq dataformat

Kenton Hokanson kenton.hokanson at POMONA.EDU
Tue Dec 25 21:06:34 CET 2007


Hi everyone,

Sorry, this is a rather basic yet lengthy question, but I've been working on
my own for some time and am totally stumped.  If there exists a more
appropriate way to get an answer to this question than to email the entire
list, please let me know; otherwise, please forgive my inexperience!
I'm trying to use FieldTrip to analyze EEG data recorded using BioPac's
"AcqKnowledge" data acquisition program (data files are saved with extension
.acq).  This is not a FieldTrip-compatible format, but using the FT FAQ (
http://www2.ru.nl/fcdonders/fieldtrip/doku.php?id=fieldtrip:dataformat) I
found the following information for importing my dataformat.

"Alternatively, if you already are able to read the data into Matlab, you
can reformat that data within Matlab into a datastructure that is compatible
with FieldTrip. Raw data that is comparable with the output of preprocessing
should consist of a structure with the fields

data.label   % cell-array containing strings, Nchan X 1
data.fsample % sampling frequency in Hz, single number
data.trial   % cell-array containing a data matrix for each trial (1 X
Ntrial), each data matrix is Nchan X Nsamples
data.time    % cell-array containing a time axis for each trial (1 X
Ntrial), each time axis is a 1 X Nsamples vector"

I'm able to save my data file as a single MATLAB matrix of dimensions
NSamples x NChannels (20073x10).  Using my knowledge of the timestamps of
events within the data file, I divided it up into two trials.  Each trial is
4001 samples long, and there are six channels that I want to analyze, so
I've pasted that data into smaller matrices (Trial1 and Trial2) each with
dimensions 6 x 4001.  Having done this, I input the following:

data.label = {'EEG_CZ' 'EEG_C3' 'EEG_F3' 'EEG_FZ' 'EEG_F4' 'EEG_C4'}
data.fsample = 1000
data.trial = {Trial1 Trial2}
data.time = {1:4001 1:4001}

Here's the output those commands generate:

data =

      label: {'EEG_CZ'  'EEG_C3'  'EEG_F3'  'EEG_FZ'  'EEG_F4'  'EEG_C4'}
    fsample: 1000
      trial: {[6x4001 double]  [6x4001 double]}
       time: {[1x4001 double]  [1x4001 double]}

It would seem to me that I have created the datastructure defined on the FAQ
site.  However, the structure doesn't appear to be usable for anything (my
guess is that a cfg structure is also necessary, but I haven't found how to
create one that is functionally identical to the output of preprocessing,
define_trials, any of the read_xxx programs from fileio)...I don't know
where to begin!  I'd very much appreciate any help I could get.  Thanks,
very happy holidays.

Best,
Kenton Hokanson

----------------------------------
The aim of this list is to facilitate the discussion between users of the FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/fcdonders/fieldtrip.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20071225/01bfdaf2/attachment-0001.html>


More information about the fieldtrip mailing list