Skip to content

vmnospikes

  VMNOSPIKES - Return underlying voltage with spikes removed

   [VMNS,T,SPIKETIMES] = VMNOSPIKES(VM, SI)

   Removes spikes from the trace VM with sample interval SI.
   Optionally, one can re-sample at a higher SI (lower sampling rate).

   SPIKETIMES that were detected are returned in SPIKETIMES.

   The behavior of this function can be modified by passing name/value
   pairs:

   Parameter (default):     | Description:
   ---------------------------------------------------------------
   newsi (si)               | If the interval is higher than si,
                            |   then the waveform is smoothed (boxcar)
                            |   and downsampled.
   filter_algorithm         | Filter algorithm: choice of 'removespikes', which employs
      ('removespikes')      |   detects spikes and removes them with REMOVESPIKES;
                            |   or 'medfilt1' which performs a median filter using MEDFILT1
   spiketimes ([])          | Extracted spike times from the trace
                            |   (if empty, then spikes are extracted using
                            |   threshold crossing and refractory period)
                            |   Spike times are in same units as SI
                            |   and are relative to Tstart
   thresh (-0.030)          | Spike threshold for spike detection (not used
                            |   if spiketimes is given)
   refract (0.0025)         | Refractory period (in same units as SI)
   MedFilterWidth           | MedFilterWidth (see MEDFILT1)
       (round(0.004/SI) )   | 
   Tstart (0)               | Time of the first sample of the VM trace
   removespikes_inputs ({}) | Any custom inputs we should pass to REMOVESPIKES
                            |   (see REMOVESPIKES)
   rm60hz (1)               | 0/1 should we filter 60Hz noise? (uses REMOVE60HZ)
   rm60hz_inputs ({})       | Any custom arguments we should pass to REMOVE60HZ
                            |   (see REMOVE60HZ)