Hi Tobias,
There are several ways to do that.
1) In SPM if you load the object with spm_eeg_load and then do D.ftraw(0) or D.fttimelock it will return the data in FT raw or timelock struct respectively.
2) In Fieldtrip you can use ft_preprocessing (or the lower level fileio functions) to read SPM datasets as any other format. You should just specify the .mat file rather than .dat for it to be recognised correctly.
3) In recent versions of Fieldtrip there is also spm2fieldtrip function which work as option (1) but also adds some more FT metadata to the struct. I don't think this function is in the FT version which comes as part of SPM though.
Best,
Vladimir
Hi Vladimir,
Is there a function to read SPM data into Fieldtrip, i.e. to read
a file created with SPM using a Fieldtrip function so that I can
then analyse the data in Fieldtrip?
Thanks,
Tobias