progressive_fusion_SMC_mixG: (Progressive) D&C Monte Carlo Fusion using SMC

View source: R/mixG_fusion.R

progressive_fusion_SMC_mixGR Documentation

(Progressive) D&C Monte Carlo Fusion using SMC

Description

(Progressive) D&C Monte Carlo Fusion with mixture Gaussian target

Usage

progressive_fusion_SMC_mixG(
  N_schedule,
  time_schedule,
  base_samples,
  n_comp,
  weights,
  means,
  sds,
  start_beta,
  precondition = TRUE,
  bounds_multiplier = 1.1,
  resampling_method = "multi",
  ESS_threshold = 0.5,
  seed = NULL,
  n_cores = parallel::detectCores()
)

Arguments

N_schedule

vector of length (L-1), where N_schedule[l] is the number of samples per node at level l

time_schedule

vector of length(L-1), where time_schedule[l] is the time chosen for Fusion at level l

base_samples

list of length (1/start_beta), where base_samples[[c]] contains the samples for the c-th node in the level

n_comp

integer number of components of mixture Gaussian

weights

vector: weights of mixture Gaussian

means

vector: means of mixture Gaussian

sds

vector: st.devs of mixture Gaussian

start_beta

beta for the base level

precondition

either a logical value to determine if preconditioning values are used (TRUE - and is set to be the variance of the sub-posterior samples) or not (FALSE - and is set to be 1 for all sub-posteriors), or a list of length (1/start_beta) where precondition[[c]] is the preconditioning value for sub-posterior c. Default is TRUE

bounds_multiplier

scalar value to multiply bounds by (should greater than or equal to 1)

resampling_method

method to be used in resampling, default is multinomial resampling ('multi'). Other choices are stratified resampling ('strat'), systematic resampling ('system'), residual resampling ('resid')

ESS_threshold

number between 0 and 1 defining the proportion of the number of samples that ESS needs to be lower than for resampling (i.e. resampling is carried out only when ESS < N*ESS_threshold)

seed

seed number - default is NULL, meaning there is no seed

n_cores

number of cores to use

Value

A list with components:

particles

list of length (L-1), where particles[[l]][[i]] are the particles for level l, node i

proposed_samples

list of length (L-1), where proposed_samples[[l]][[i]] are the proposed samples for level l, node i

time

list of length (L-1), where time[[l]][[i]] is the run time for level l, node i

ESS

list of length (L-1), where ESS[[l]][[i]] is the effective sample size of the particles after each step BEFORE deciding whether or not to resample for level l, node i

CESS

list of length (L-1), where CESS[[l]][[i]] is the conditional effective sample size of the particles after each step

resampled

list of length (L-1), where resampled[[l]][[i]] is a boolean value to record if the particles were resampled after each step; rho and Q for level l, node i

precondition_values

preconditioning values used in the algorithm for each node

diffusion_times

vector of length (L-1), where diffusion_times[l] are the times for fusion in level l


rchan26/hierarchicalFusion documentation built on Sept. 11, 2022, 10:30 p.m.