Back to the main page.

Bug 929 - xxx2fieldtrip function user interface should be made more consistent

Status CLOSED FIXED
Reported 2011-09-03 17:07:00 +0200
Modified 2012-01-31 12:12:49 +0100
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P1 enhancement
Assigned to: Johanna
URL:
Tags:
Depends on:
Blocks:
See also:

Robert Oostenveld - 2011-09-03 17:07:59 +0200

There is a bunch of xxx2fieldtrip functions. It would be good to give them consistent names and to make their user interface as consistent as possible.


Robert Oostenveld - 2011-09-05 16:09:03 +0200

On 5 Sep 2011, at 11:04, Johanna Zumer wrote: About the bug 929 on *2fieldtrip, I'm happy to do this but what do you have in mind? For inputs, there is a range of either filenames, directory names, or data structures or objects. For outputs, there can be either raw, timelock, source, spike, etc depending on the function or input to that function. (and with spass I'm not so clear on some of the outputs). For Nutmeg, do you prefer there to be only 1 function, rather than 2 separate for source versus raw conversion, so that there is only one nutmeg2fieldtrip.m function?


Robert Oostenveld - 2011-09-05 16:15:59 +0200

I think it would be good to have a single xxx2yyy function for each of the platforms. The options that the function has should differentiate (if needed) between the different data types. In external/eeglab/eeglab2fieldtrip that is done with the interface % Usage: >> data = eeglab2fieldtrip( EEG, fieldbox, transform ); % % Inputs: % EEG - [struct] EEGLAB structure % fieldbox - ['preprocessing'|'freqanalysis'|'timelockanalysis'|'companalysis % transform - ['none'|'dipfit'] transform channel locations for DIPFIT % using the transformation matrix in the field % 'coord_transform' of the dipfit substructure of the EEG % structure. Here the fieldbox is the type of function that is emulated. Another example: for besa2fieldtrip the conversion is implicitly determined by the input file format. I suggest a single function that behaves either as [raw,grid,mri]=nutmet2fieldtrip(nuts) or as [source] = nutmet2fieldtrip(beam) depending on the input. The function can have some simple varargins for more options.


Johanna - 2011-09-06 14:57:09 +0200

Completed for Nutmeg. Still yet to look at the other conversions.


Robert Oostenveld - 2011-09-12 11:34:23 +0200

I renamed spm2ft into spm2fieldtrip for consistency


Robert Oostenveld - 2011-09-12 11:35:01 +0200

(In reply to comment #3) > Completed for Nutmeg. Still yet to look at the other conversions. there is still not a single nutmeg2fieldtrip function....


Robert Oostenveld - 2011-09-12 12:32:58 +0200

(In reply to comment #5) > (In reply to comment #3) > > Completed for Nutmeg. Still yet to look at the other conversions. > > there is still not a single nutmeg2fieldtrip function.... sorry, now there is. I had not done an svn update for too long. My fault!


Johanna - 2012-01-11 15:21:26 +0100

There are 4/5 which are now consistent (besa, loreta, nutmeg, spm)2fieldtrip. Robert, are you happy with the 5th one: [lfp,spike,stm,bhv]=spass2fieldtrip(dirname) as meeting the criteria of 'user interface consistent as possible'?


Robert Oostenveld - 2012-01-11 17:55:30 +0100

(In reply to comment #7) Yep, I think this is as good as it gets.


Johanna - 2012-01-11 18:05:56 +0100

no outstanding issues.