**Xi'an's Og » R**, and kindly contributed to R-bloggers)

**I**n the previous days I have received several emails asking for clarification of the effective sample size derivation in “** Introducing Monte Carlo Methods with R**” (Section 4.4, pp. 98-100). Formula (4.3) gives the Monte Carlo estimate of the variance of a self-normalised importance sampling estimator (note the change from the original version in

**! The weight**

*Introducing Monte Carlo Methods with R**W*is unnormalised and hence the normalising constant appears in the denominator.)

as

Now, the front term is somehow obvious so let us concentrate on the bracketed part. The empirical variance of the ‘s is

the coefficient is thus estimated by

which leads to the definition of the effective sample size

The confusing part in the current version is whether or not we use normalised W’s and ‘s. I hope this clarifies the issue!

Filed under: Books, R, Statistics Tagged: effective sample size, importance sampling, Introducing Monte Carlo Methods with R

**leave a comment**for the author, please follow the link and comment on his blog:

**Xi'an's Og » R**.

R-bloggers.com offers

**daily e-mail updates**about R news and tutorials on topics such as: visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...