set.SB {BBEST}R Documentation

Set the coherent baseline

Description

set.SB sets the baseline, describing coherent neutron scattering caused by uncorrelated atomic motion or any other baseline that needs to be preserved in the recovered signal.

Usage

			 
set.SB(data, SB=NA, n.atoms=NA, scatter.length=NA, ADP=NA, 
       fit=FALSE, oneADP=TRUE, ADP.lim = c(0, 0.05))

Arguments

data

an object of type data. See set.data for details.

SB

numeric vector which, if not NA, determines the baseline. See BBEST-package for details.

n.atoms, scatter.length, ADP

numerics. Specify the number of atoms of each atomtype in the unit cell, atomic scattering factors and atomic displacement parameters (ADP), respectively.

fit

logical, whether to fit ADP.

oneADP

logical. If TRUE a single parameter is used for all the APDs.

ADP.lim

numeric vector that specifies the lower and upper bounds for the fitted ADP.

Details

Baseline SB has to be specified. If no baseline is needed fill SB with zeroes. If n.atoms, scatter.length and ADP parameters are specified, the baseline is calculated according to

SB(x) = 1 - \frac{ ∑_i{N_i f_i^2 e^{-ADP_i x^2}} }{ N<f^2> }(1 - \frac{<f>^2-<f^2>}{<f>^2}).

If ADP parameters are to be fitted, indicate n.atoms, scatter.length and set parameter fit to TRUE. Set oneADP to the desired value.

Value

An object of type data. Element

SB

numeric vector containing the baseline.

is replaced with its new value. Element

fitADP

a list of values.

might be added to describe the fit details.


[Package BBEST version 0.1-8 Index]