pspm_tam

Back to index

Description

TAM stands for Trial Average Model and allows to fit models on trial-averaged data.

pspm_tam starts by extracting and averaging signal segments of length model.window from each data file individually, then averages these mean segments and finally fits an LTI model.

Arguments

Variable Definition      
model See following fields.      
model.modelfile a file name for the model output.      
model.datafile a file name (single session) OR a cell array of file names.      
model.timing a multiple condition file name (single session) OR a cell array of multiple condition file names OR a struct (single session) with fields .names, .onsets, and (optional) .durations OR a cell array of struct OR a struct with fields ‘markerinfos’, ‘markervalues’, ‘names’ OR a cell array of struct.      
model.timeunits a char array equal to ‘seconds’, ‘samples’ or ‘markers’.      
model.window a scalar in model.timeunits as unit that specifies over which time window (starting with the events specified in model.timing) the model should be evaluated. For model.timeunits == ‘markers’, the unit of the window should be specified in ‘seconds’.      
model.modelspec [optional] ‘dilation’ (default); specify the model to be used. See pspm_init, defaults.tam() which modelspecs are possible with glm.      
model.modality [optional] specify the data modality to be processed. By default, this is determined automatically from “modelspec”.      
model.bf See following fields.      
model.bf.fhandle function handle or string.      
model.bf.args arguments; the first two arguments (time resolution and duration) will be added by pspm_pupil_model. DEFAULT: specified by the modality.      
model.if See following fields.      
model.if.fhandle function handle or string.      
model.if.arg initial arguments, numeric array.      
model.if.lb lower bounds, numeric array of the same size as .arg.      
model.if.ub upper bounds, numeric array of the same size as .arg.      
model.channel [optional] allows to specify channel number or channel type. If there is only one element specified, this element will be applied to each datafile. DEFAULT: last channel of ‘pupil’ data type.      
model.norm [optional] allows to specify whether data should be zscored or not DEFAULT: 1.      
model.filter [optional] filter settings; modality specific default.      
model.baseline [optional] allows to specify a baseline in ‘seconds’ which is applied to the data before fitting the model. It has to be positive and smaller than model.window. If no baseline specified, data will be baselined wrt. the first datapoint. DEFAULT: 0.      
model.std_exp_cond [optional] allows to specify the standard experimental condition as a string or an index in timing.names. if specified this experimental condition will be substracted from all the other conditions. DEFAULT: ‘none’.      
model.norm_max [optional] set the first peak at 1 before model fitting. DEFAULT: 0 (not normalize).   options See following fields.
options.marker_chan marker channel number DEFAULT: ‘marker’ (i.e. last marker channel).      
options.overwrite (optional) overwrite existing model output; [logical] (0 or 1) Define whether to overwrite existing output files or not. Default value: determined by pspm_overwrite.      

Outputs

Variable Definition
tam a structure ‘tam’ which is also written to file.

Back to index