renewal {ltable}R Documentation

Function renewal

Description

Estimates MCMC chain convergence based on renewal theory.

Usage

renewal(x, StatesNum=10, Astate=NULL, nForStart = 3000, epsilon1=0.05, epsilon2=0.05)

Arguments

x

name of the numeric vector of the chain; object of numeric class

StatesNum

positive integer that indicates the number of states to classify chain values into, max value is 100 s.t. values of chain classified into 100 ordered states; to choose StatesNum consider the adequate number of unique intervals chain values can be suitably represented by

Astate

positive integer from 1 to StateNum that defines state to base calculation on; there may be small differences in results under different base states, see help for details; default is median state value

nForStart

positive integer that indicates the maximum distance from beginning of chain to consider in finding Start value, 3000 by default

epsilon1

upper bound of closeness to stationary distribution \pi_X; it is used to calculate the starting position of the chain nstat

\|P^{nstat}_{x0} - \pi_X \| \leqslant \epsilon_1

epsilon2

is upper bound of variance of estimator

Var(\frac{1}{\ell}\sum^{nvar}_{nstat+1}X_k - E_{\pi_X}) \leqslant \epsilon_2

Details

Value

returns two positive integers, starting value of the chain and length of the chain to be used from starting value.

Note

Abstain from repeated supply of lengthier chain. It does not correct the problem of nonstationarity.

Author(s)

Ocheredko Oleksandr Ocheredko@yahoo.com

Examples

require(ltable)
data(tdata, package="ltable")
res1<-MCLogLin(Counts~smoker +contraceptive +tromb +
contraceptive*tromb, data=tdata, draw=5000, burnin=500)
renewal(res1[,1], Astate=5)
renewal(res1[,14], Astate=1)


[Package ltable version 2.0.4 Index]