mcmc_bspbss {BSPBSS}R Documentation

MCMC algorithm for Bayesian spatial blind source separation with the thresholded Gaussian Process prior.

Description

Performan MCMC algorithm to draw samples from a Bayesian spatial blind source separation model.

Usage

mcmc_bspbss(
  X,
  init,
  prior,
  kernel,
  n.iter,
  n.burn_in,
  thin = 1,
  show_step,
  ep = 0.01,
  lr = 0.01,
  decay = 0.01,
  num_leapfrog = 5,
  subsample_n = 0.5,
  subsample_p = 0.5
)

Arguments

X

Data matrix with n rows (sample) and p columns (voxel).

init

List of initial values, see init_bspbss.

prior

List of priors, see init_bspbss.

kernel

List including eigenvalues and eigenfunctions of the kernel, see init_bspbss.

n.iter

Total iterations in MCMC.

n.burn_in

Number of burn-in.

thin

Thining interval.

show_step

Frequency for printing the current number of iterations.

ep

Approximation parameter.

lr

Per-batch learning rate in SGHMC.

decay

Decay parameter in SGHMC.

num_leapfrog

Number of leapfrog steps in SGHMC.

subsample_n

Mini-batch size of samples.

subsample_p

Mini-batch size of voxels.

Value

List containing MCMC samples of: A, b, sigma, and zeta.

Examples


sim = sim_2Dimage(length = 30,
                  sigma = 5e-4,
                  n = 30,
                  smooth = 6)
ini = init_bspbss(sim$X, sim$coords,
                  q = 3,
                  ker_par = c(0.1,50),
                  num_eigen = 50)
res = mcmc_bspbss(ini$X,ini$init,
                  ini$prior,ini$kernel,
                  n.iter=200,n.burn_in=100,
                  thin=10,show_step=50)


[Package BSPBSS version 1.0.5 Index]