Reweighting and Error Bars
Reweighting estimates a new expectation from configurations sampled under a reference distribution. It is useful when the two ensembles overlap well. Its uncertainty depends on correlated fluctuations of a numerator and denominator, so treating them as independent estimates can give a badly wrong error bar.
Required background. Monte Carlo basics defines importance sampling; autocorrelation analysis determines appropriate blocking.
The self-normalized ratio
Section titled “The self-normalized ratio”Suppose the target is proportional to and samples come from normalized . For nonnegative weights with finite nonzero expectation,
Unknown common weight normalization cancels. At finite , the ratio is generally biased; under regularity and finite-moment conditions, the leading bias is typically . Consistency requires enough overlap and an appropriate law of large numbers.
To avoid overflow, subtract a common maximum log weight before exponentiating. This preserves the ratio exactly in exact arithmetic, but cannot restore configurations that were never sampled.
The fluctuation that controls uncertainty
Section titled “The fluctuation that controls uncertainty”Let and . Linearizing the ratio around its true means gives
For independent draws, its leading variance is
The covariance is already included in this expression. For a chain, sum autocovariances of the combined fluctuation , or use blocks long enough for that fluctuation. The autocorrelation time of alone may be irrelevant when rare large weights dominate.
A two-state example
Section titled “A two-state example”Sample states zero and one equally under . Let and . The target mean is . The independent ratio variance to leading order is : takes values , and .
Computing separate numerator and denominator errors while omitting their covariance gives a different, incorrect result. Enumerating binomial counts of the two states also reveals finite- ratio bias. This small example is useful for verifying a jackknife implementation without trusting a large simulation.
Blocked jackknife and bootstrap
Section titled “Blocked jackknife and bootstrap”Partition a production series into equally long contiguous blocks. Keep each block’s numerator sum and denominator sum together. For leave-one-block-out ratios , let their average be . The jackknife variance estimate is
Recompute the full nonlinear ratio on every deletion. For a block bootstrap, resample whole blocks and recompute the ratio on each resample. Resampling individual observations from a correlated chain understates uncertainty. Use enough blocks to estimate the error, and verify stability as block length changes.
If leave-one-out denominators approach zero or resamples become highly skewed, the usual Gaussian interval may be unjustified. This is a diagnostic to report, not a reason to discard inconvenient resamples.
Overlap and effective weighted counts
Section titled “Overlap and effective weighted counts”For nonnegative weights, is a useful weight-concentration diagnostic. It is not a complete variance formula and does not include Markov correlation or dependence of on the weights. Inspect largest normalized weights and stability under independent reference runs.
Signed or complex weights require sign/phase analysis; a positive-weight effective-count formula does not certify their ratio uncertainty.
Exercises
Section titled “Exercises”If one sample carries essentially all normalized weight, what happens to the weighted effective count and the reliability of a nominally large run?
Solution
The diagnostic tends to one, regardless of the total stored sample count. The result is controlled by a single configuration and usually cannot support a stable uncertainty estimate. More samples help only if they actually explore the target-relevant region; moving the reference ensemble closer may be necessary.
References
Section titled “References”- Flyvbjerg, H., and H. G. Petersen, “Error estimates on averages of correlated data,” The Journal of Chemical Physics 91, 461–466 (1989), doi:10.1063/1.457480 — blocking correlated measurements.
- Hastings, W. K., “Monte Carlo sampling methods using Markov chains and their applications,” Biometrika 57, 97–109 (1970), doi:10.1093/biomet/57.1.97 — stationary sampling and proposal correction.