[FieldTrip] reading in ascii files

Eelke Spaak eelke.spaak at donders.ru.nl
Tue Nov 18 11:53:08 CET 2014


Hi Martine,

You mentioned that you are already able to get it into Matlab, so my
guess is that the best way to read it into FieldTrip is to get it into
a generic Matlab array first, and then hack a bit to make it
FT-compatible.

If the data is not segmented yet, you can convert it into one big
'trial', and subsequently use ft_redefinetrial to get it segmented. A
typical raw data structure would be:

data = [];
data.label = {'chan1'...'chanN'};
data.time = {0:1/fsample:tEnd};
data.trial = {dat}; % where dat is channel X timepoint

For more details, see the help and code of ft_datatype_raw.

Hope that helps!
Best,
Eelke

On 11 November 2014 02:45, Martine van Schouwenburg
<martine.vanschouwenburg at ucsf.edu> wrote:
> Hi all,
>
>
>
> I have been using a new (wireless and dry!) EEG cap called Enobio
> (http://www.neuroelectrics.com/ ). It saves the data in a non-traditional
> format called .easy files, but they are basically just ascii files that can
> be read with dlmread into matlab. Is anyone aware of a way I can read these
> files into Fieldtrip? I tried changing the extension to .txt, because on the
> Fieldtrip website it mentions this as one of the supported data formats (for
> NIRS though..), but I get the following error.
>
>
>
> Error using ft_read_header (line 1833)
>
> unsupported header format (ascii_txt)
>
>
>
> I guess it makes sense cause there is no header in the file. J It is just a
> table with number of electrodes x number of data points. If anyone has
> succeeded in the past to read in ascii files into Fieldtrip, or has any idea
> on how to achieve this, I would very much appreciate your advice!
>
>
>
> Thanks!
>
>
>
> Best,
>
> Martine van Schouwenburg
>
>



More information about the fieldtrip mailing list