This function takes current parameters and observed data, gives an updated site level linear coefficients.
updateGamma(X, Y, Z, delta,
Beta, Gamma, E, R,
S, Ds, mu, mustar,
sigma, c, step, runif,
n, m, T0, p, q, D, theta,tau)
updateGamma(X, Y, Z, delta, Beta, Gamma, E, R, S, Ds, mu, mustar, sigma, c, step, runif, n, m, T0, p, q, D, theta,tau)
returns a list with following variables:
the updated site level linear coefficients
the updated mu computed by updated Gamma
the updated mustar computed by updated Gamma
the patient level covariate matrix
the CAL observation matrix, with missing values
the site level covariate matrix
the missing indicator matrix, with 1 means missing
current patient level linear coefficients matrix
current site level linear coefficients array
current patient level clustering vector
current site level clustering matrix
number of patient level clusters
a vector recording numbers of site level clusters
current estimated mean matrix for CAL
current matrix of latent value for missingness model
current estimated noise variance
current c for missingness model. It is a vector
an array of steps for M-H
an array of uniform random variables for deciding whether to accept new proposed point in M-H
number of patients
number of sites
number of teeth
dimension of patient level covariates
dimension of site level covariates
the D matrix in the paper
parameter for DPP
parameter for DPP
Yuliang Li
update_RJ for a complete example for all functions in this package.