Produced by IDL 6.1
User Documentation

./guide
baseline.pro

Last modification date:
Thu Jun 2 23:56:08 2005

baseline

procedure baseline, [nfit=integer], [modelindex=integer], [ok=variable]

Fit and subtract a polynomial baseline from the contents of data container [0] (continuum or line, depending on the GUIDE mode at the time).

See the notes for bshape for more details since this procedure uses that one for much of its work.

Use bshape if you want to fit the baseline but do not want it subtracted from the data.

Use bsubtract to subtract a baseline using the baseline coeficients stored in the !g structure (e.g. from a use of bshape).

Use bmodel to generate a baseline model and store it in the DC specified in modelindex.

Use bshow to over plot a baseline model.

Use subtract to subtract one data container (which might contain a basline model) from another data container.

Examples
Get some data, set some regions, fit a 2nd order polynomial, putting the model (fitted baseline) into !g.s[10].
 get,index=20
 nregion,[100,500,700,1000,1600,2000]
 !g.nfit=2
 baseline,modelindex=10
 
The step involving !g.nfit can be omitted with the same result.
 baseline,nfit=2,modelindex=10
 
Same fit, but don't put the model into any of the data containers.
 baseline,nfit=2
 
Uses
bshape bsubtract
Version
$Id: baseline.pro,v 1.4 2005/04/26 19:12:27 bgarwood Exp $

Keywords
nfit
in, optional
integer
The order of polynomial to fit. Defaults to !g.nfit. If set, then this also sets the value of !g.nfit.
modelindex
in, optional
integer
The index number to hold the fit evaluated at all channels (the model). If not set then no index will hold the model after this procedure is used.
ok
out, optional
variable
1 on success, 0 on failure.


Produced by IDLdoc 1.6 on Thu Jun 2 23:56:46 2005