User Tools

Site Tools


plotcurves

This is an old revision of the document!


plotcurves

Motivation

Some physiological measurements require more human inspection and interaction to be good enough for additional analyses (e.g. in a GSR peak-to-peak analysis). This function allows to visualize parts of a measurement (e.g. GSR data channel) as single curves (e.g. 15-second windows following onsets).

Requirements

The physiological data must be available as a one of the supported object types, ACQ or NTT. It is fairly simple to store any channel data in a new NTT object, if necessary:

plotcurves_new_ntt.m
% load data from a MAT file
load HPS1344_session1_GSR.mat;
 
% create new NTT
ntt = xff('new:ntt');
 
% store data from mat file in ntt
ntt.Data = data;

Function reference ('help plotcurves')

  plotcurves  - plot different curves and select those of interest
 
  FORMAT:       [sel, var, spot, sets] = plotcurves(obj [, opts]]);
 
  Input fields:
 
        obj         xff object with plotable data
        opts        optional settings
         .curves    Cx2 cell array with names and a 1x3 double array
                    containing [channelnumber, onset, offset]
                    for multiple curves, the mean will be computed
         .freq      data sampling frequency (if not in object)
         .resfreq   resampling frequency
         .sets      Sx2 cell array with names and lists of curve indices
         .spot      Sx1 cell array with Cx1 X or Cx2 x/y coordinates
         .spotnames Sx1 cell array with strings
         .var       1xV struct with fields
           .calc    either of {'xdiff'}, 'xval', 'ydiff', 'yval'
           .spots   1x1 or 1x2 index into S
           .trans   apply additional transformation to each value, one of
                    {'none'}, 'log', 'log+1', 'sqrt'
         .varnames  
 
  Output fields:
 
        sel         selection (Cx1 boolean array)
        var         computed variables
        spot        updated spots
        sets        updates sets (new indices)

GUI

This function has its own GUI. Once called (with appropriate parameters), the following dialog will open:

Usage

plotcurves.1276879173.txt.gz · Last modified: 2010/06/18 16:39 by jochen