AMIS: Adaptive Importance Sampling Adaptive Multiple Importance...

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/AMIS.R

Description

Functions implementing Adaptive IS and constructors for object ISO.

Usage

1
2
3
AIS(N,niter,p,target,proposal=mvtComp(df=3),initialize,mixture,verbose=FALSE,tol=0.001,seed=NULL)

AMIS(N,niter,p,target,proposal=mvtComp(df=3),initialize=uniInit(),mixture,verbose=FALSE,parallel = c("no", "multicore", "snow"),nCores=-1,cl=NULL,tol=0.001,seed=NULL,...)

Arguments

N

Vector of length 3 with the sample size for the initialization and for the first and second Sampling phase, or a scalar if the three above are the same.

niter

Vector of length 2 with the number of iterations for the first and the second Sampling phase, or a scalar if the two above are the same.

p

Dimension of the sample space.

target

Target distribution. Takes as an argument a matrix with p columns and returns a value of the log-density for each row (observation). See target.

proposal

A list with two components: d and r, to compute the Proposal Importance distribution and to simulate from it. Takes as an argument a matrix with p columns (or the size of the sample), a p dimensional vector mu and a pXp matrix Sig and returns a value of the density for each observation (or the simulated sample). See proposal. Default is a 3 degrees of freedom multivariate t distribution.

initialize

See initialize. Function for the initialization. Takes as an argument:

N0

Sample Size of the Initialization phase

p

Dimension of the sample space.

target

As described above

verbose

and returns a list with components:

w

Vector with initial Importance weights.

xx

Vector with initial Sample.

var

Initial variance.

targ

Initial Value of the target distribution (log-scale)

prop

Initial Value of the proposal distribution (log-scale)

Default is a random initialization.

mixture

See mixture. Function for the parametric clustering. Takes as an argument a matrix with p columns and returns:

alpha

Vector of Cluster Proportions

muHat

Matrix with cluster means by rows. Dimensions GXp.

SigmaHat

Array of Variance-Covariance matrix. Dimensions pXpXG.

G

Number of components

cluster

Labels vector.

verbose

Default FALSE. Helps to spend the time while the function is running ;).

parallel

"multicore" doesn't work on Windows systems

nCores

Number of cores to be used.

cl

A cluster object to be used if by the prallel implementation.

seed

initial seed for the (pseudo-)random number generator.

tol

a tolerance for the error

...

further arguments to be passed to subroutines

Value

An Object of class ISO, see ISO.

Author(s)

Luca Pozzi, p.luc@stat.berkeley.edu

References

Jean-Marie Cornuet, Jean-Michel Marin, Antonietta Mira and Christian Robert (2012), Adaptive Multiple Importance Sampling, Scandinavian Journal of Statistics

See Also

See also initialize, mixture and target. See demoARAMIS vignette for more information.

Examples

1
2
ais <- AIS(N=50,niter=c(5,10),p=2,target= targetBanana(),initialize=uniInit(),mixture= mclustMix())
amis <- AMIS(N=c(10,50,100),niter=10,p=2,target=targetBanana(),initialize= amisInit(maxit=5), mixture=mclustMix(),verbose=TRUE)

thq80/Cornuet_2012_Adaptive-Mutiple-IS documentation built on May 21, 2019, 9:23 a.m.