sample_me: Collapsed Gibbs sampler for hWRU. Internal function

View source: R/RcppExports.R

sample_meR Documentation

Collapsed Gibbs sampler for hWRU. Internal function

Description

Collapsed Gibbs sampler for hWRU. Internal function

Usage

sample_me(
  last_name,
  first_name,
  mid_name,
  geo,
  N_rg,
  pi_s,
  pi_f,
  pi_m,
  pi_nr,
  which_names,
  samples,
  burnin,
  race_init,
  verbose
)

Arguments

last_name

Integer vector of last name identifiers for each record (zero indexed; as all that follow). Must match columns numbers in M_rs.

first_name

See last_name

mid_name

See last_name

geo

Integer vector of geographic units for each record. Must match column number in N_rg

N_rg

Integer matrix of race | geography counts in census (geograpgies in columns).

pi_s

Numeric matrix of race | surname prior probabilities.

pi_f

Same as pi_s, but for first names.

pi_m

Same as pi_s, but for middle names.

pi_nr

Matrix of marginal probability distribution over missing names; non-keyword names default to this distribution.

which_names

Integer; 0=surname only. 1=surname + first name. 2= surname, first, and middle names.

samples

Integer number of samples to take after (in total)

burnin

Integer number of samples to discard as burn-in of Markov chain

race_init

Integer vector of initial race assignments

verbose

Boolean; should informative messages be printed?


wru documentation built on May 29, 2024, 9:46 a.m.