do.iter {BBEST} | R Documentation |
Estimate the background
Description
do.iter
performs adaptive Bayesian estimation of the background.
Usage
do.iter(fit.results, local = TRUE, eps = 1e-04,
n.iter = 10000, save.to = "")
Arguments
fit.results |
list. The return value of |
local |
logical. If |
eps |
numeric, the desired accuracy for spline values. |
n.iter |
numeric, number of iterations for a gradient descent method, see details. |
save.to |
character, the filename for saving the results. |
Details
An adaptation of neutron scattering data for a Bayesian background separation procedure. The method is detailed elsewhere*.
First, use the function do.fit
to estimate the background from the low-r information in G(r). do.iter
procedure estimates the background without low-r information, calculates the difference between the two estimates, subtracts this difference from the scattering data and finds the new estimate of the background.
Value
An object fit.results
with modified elements fit.results$curves$bkg
, fit.results$curves$y
and fit.results$curves$corr
. See do.fit
for details.
References
*Gagin, A. and Levin, I. Hydrogen background estimation in neutron total scattering experiments. Submitted for publication.