ess {batchmeans} | R Documentation |

## Estimate effective sample size (ESS) as described in Kass et al. (1998) and Robert and Casella (2004; p. 500).

### Description

Estimate effective sample size (ESS) as described in Kass et al. (1998) and Robert and Casella (2004; p. 500).

### Usage

```
ess(x, imse = TRUE, verbose = FALSE)
```

### Arguments

`x` |
a vector of values from a Markov chain. |

`imse` |
logical. If |

`verbose` |
logical. If |

### Details

ESS is the size of an iid sample with the same variance as the current sample. ESS is given by

`\mbox{ESS}=T/\eta,`

where

`\eta=1+2\sum \mbox{all lag autocorrelations}.`

### Value

The function returns the estimated effective sample size.

### References

Kass, R. E., Carlin, B. P., Gelman, A., and Neal, R. (1998) Markov chain Monte Carlo in practice: A roundtable discussion. *The American Statistician*, **52**, 93–100.

Robert, C. P. and Casella, G. (2004) *Monte Carlo Statistical Methods*. New York: Springer.

Geyer, C. J. (1992) Practical Markov chain Monte Carlo. *Statistical Science*, **7**, 473–483.

*batchmeans*version 1.0-4 Index]