[resp_auto, resp_labels] = trialSummaryFunc_object(trialtable [,datastruct] [,varargin])


DRAWFUNC_OBJECT is an example use of draw_func that is written to be run on easyScale datastructs that have used inputFunc_object for input. It will generate some sample statistics (distance dragged) that are more meaningful for summary than a long vector of xy screen coordinates. The function can be supplied to initEasyScale when data is initially collected, or as a parameter to easyScore after the fact.


As a trial_summary_func, this function is meant to be called internally by other functions. It should expect to receive the datastruct.trials table one row at a time. To work properly in this way, it needs to satisfy the interface for trial_summary_funcs. This takes the form: [resp_auto, resp_labels] = objectScoreFunc(trialtable, datastruct, args) Where "trialtable" is the active row of the trials table, and "datastruct" is the datastruct stripped of the trials table. In this example, we don't really need the datastruct, but it's there if you need to access e.g., info from your stimmap or parameters.


resp_auto: a numeric vector of statistics computed by this scoring function. resp_labels: a cell array of strings containing a variable name for each column of resp_auto.