lda_fgs_hs: The LDA Full Gibbs sampler (FGS) with Selection of h

Description Usage Arguments Value See Also

View source: R/lda_fgs_hs.R

Description

This a Markov chain on (z, β, θ)

Usage

1
2
lda_fgs_hs(K, V, wid, doc.N, alpha, eta, h.grid, max.iter, burn.in, spacing,
  save.z, save.beta, save.theta, save.Bh, save.lp)

Arguments

K

the number of topics in the corpus

V

the vocabulary size

wid

the vocabulary ids of every word instance in each corpus document

doc.N

the document lengths

alpha

the hyper parameter for θ

eta

the β matrix smoothing parameter

h.grid

the grid of hyperparamets (η, α), 2 x G matrix, where G is the number of grid points and the first row is for α points and the second row is for η points

max.iter

the max number of Gibbs iterations to be performed

burn.in

the burn in period of the Gibbs sampler

spacing

the spacing between the stored samples (to reduce correlation)

save.z

if 0 the function does not save z samples

save.beta

if 0 the function does not save β samples

save.theta

if 0 the function does not save θ samples

save.Bh

if 0 the function does not save computed B(h, h_*) values for iterations

save.lp

if 0 the function does not save computed log posterior for iterations

Value

the Gibbs sampling output

See Also

Other Gibbs sampling methods: get_grid_neighbors, lda_acgs_hs, lda_acgs, lda_fgs_st, lda_fgs


clintpgeorge/ldamcmc documentation built on Feb. 22, 2020, 12:39 p.m.