mvpa2.misc.fsl.base.FslEV3¶
-
class
mvpa2.misc.fsl.base.FslEV3(source)¶ IO helper to read FSL’s EV3 files.
This is a three-column textfile format that is used to specify stimulation protocols for fMRI data analysis in FSL’s FEAT module.
Data is always read as
float.Attributes
durationsintensitiesncolumnsReturns the number of columns. nevsReturns the number of EVs in the file. nrowsReturns the number of rows. onsetsMethods
clear()copy()fromkeys(S[,v])v defaults to None. get(k[,d])get_ev(evid)Returns a tuple of (onset time, simulus duration, intensity) for a certain EV. has_key(k)items()iteritems()iterkeys()itervalues()keys()pop(k[,d])If key is not found, d is returned if given, otherwise KeyError is raised popitem()2-tuple; but raise KeyError if D is empty. select_samples(selection)Return new ColumnData with selected samples setdefault(k[,d])to_events(**kwargs)Convert into a list of Eventinstances.tofile(filename)Write data to a FSL EV3 file. update([E, ]**F)If E present and has a .keys() method, does: for k in E: D[k] = E[k] If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v In either case, this is followed by: for k in F: D[k] = F[k] values()viewitems()viewkeys()viewvalues()Read and write FSL EV3 files.
Parameters: source : str
Filename of an EV3 file
Attributes
durationsintensitiesncolumnsReturns the number of columns. nevsReturns the number of EVs in the file. nrowsReturns the number of rows. onsetsMethods
clear()copy()fromkeys(S[,v])v defaults to None. get(k[,d])get_ev(evid)Returns a tuple of (onset time, simulus duration, intensity) for a certain EV. has_key(k)items()iteritems()iterkeys()itervalues()keys()pop(k[,d])If key is not found, d is returned if given, otherwise KeyError is raised popitem()2-tuple; but raise KeyError if D is empty. select_samples(selection)Return new ColumnData with selected samples setdefault(k[,d])to_events(**kwargs)Convert into a list of Eventinstances.tofile(filename)Write data to a FSL EV3 file. update([E, ]**F)If E present and has a .keys() method, does: for k in E: D[k] = E[k] If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v In either case, this is followed by: for k in F: D[k] = F[k] values()viewitems()viewkeys()viewvalues()-
durations¶
-
get_ev(evid)¶ Returns a tuple of (onset time, simulus duration, intensity) for a certain EV.
-
intensities¶
-
nevs¶ Returns the number of EVs in the file.
-
onsets¶
-
to_events(**kwargs)¶ Convert into a list of
Eventinstances.Parameters: kwargs
Any keyword arugment provided would be replicated, through all the entries. Useful to specify label or even a chunk
-
tofile(filename)¶ Write data to a FSL EV3 file.
-