Produced by IDL 7.1.1
User Documentation

./guide
fshift.pro

Last modification date:
Wed Sep 28 13:27:08 2016

fshift

function fshift(accumnum, [buffer=integer], [frame=string])

Function to calculate the shift, in channels, necessary to align in frequency the primary data container with the data container template in an ongoing accumulation.

You can use an alternate data container by setting buffer. You can use an alternate global accumulation buffer by setting accumnum.

If the frame is not set, the one implied by the data header is used. Use xshift to align using the current settings of the plotter's x-axis.

Returns
shift, in channels, to be used as argument to shift. Returns 0.0 on failure.
Examples
 getps,30
 accum             ; accum first spectrum, no alignment needed yet
 getps,31
 fs = fshift()     ; determine the shift to align scan 31 with scan 30
 gshift,fs         ; apply the shift to scan 31
 accum             ; and add the result to the accumulator
 getps, 32
 gshift, fshift()  ; all in one line, shift scan 32 to align with scan 30
 accum
 ave
 
Uses
dcfshift
Version
$Id$

Parameters
accumnum
in
integer (def. 0)
accum buffer to use. Defaults to the primary buffer, 0. There are 4 buffers total so this value must be between 0 and 3, inclusive.

Keywords
buffer
in, optional
integer (def. 0)
The global buffer that will eventually be shifted. Defaults to the primary data container (buffer 0).
frame
in, optional
string
The reference frame to use. If not supplied, the value implied by the last 4 characters of the velocity_definition in the ongoing accumulation will be used. See frame_velocity for a full list of supported reference frames.


Produced by IDLdoc 1.6 on Wed Sep 28 13:27:34 2016