[FieldTrip] Working with own data format - events

Eelke Spaak eelke.spaak at donders.ru.nl
Wed Mar 16 12:16:45 CET 2011


Dear Marco,

1) You can use Matlab's find-function for this, for instance, use
something like cfg.trials = find(data.trialinfo(:,1) == 1); to select
all trials for which the first row in your trialinfo-matrix equals 1.
The subsequent FT function you call with cfg as its argument will
limit its processing only to the trials you specified.

2) The answer to this question depends a bit on what *you* define
'events' to be. In general, I would say events and trials are not the
same; an event is something like a trigger that might occur in your
data (i.e., something "pinpointable" in time), whereas a trial is a
segment of data (i.e., something that has a duration). Since I do not
know exactly what you mean by 'event' in your question, I cannot
answer it with certainty. However, a possible answer could be: yes,
you could just use ft_redefinetrials again :)

Do not hesitate to rephrase your question 2, I might be able to give
you some more detailed help.

Best,
Eelke

2011/3/16 Marco Dahmane <marco.dahmane at gmail.com>:
> Dear Jan-Mathijs,
> Thank you for your kind answer. I have now created a trialinfo field, but
> that raises two other questions :
> 1) How would I go about if I want to perform an action on one trial-type
> only?
> 2) And now say that within these condition-specific trials, I want to define
> smaller events. Would I need to proceed the same way as I did with
> ft_redefinetrials in the first steps? (That is, does FT consider events and
> trials to be the same thing?)
> Thank you again,
> Marco
> PS : it would be nice indeed to have a tutorial on how to work with one's
> own dataformat (or to slightly expand the How can I import my own
> dataformat section in the FAQ)
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>




More information about the fieldtrip mailing list