Usage
bayMCMC_semi_local(data_x, data_y, data_xnew, Xvar, Xvarpred, warm = 1000, M = 1000,
mutprob = 0.44, errorprob = 0.44, epsilonprob = 0.44, mutsizp = 1, errorsizp = 1,
epsilonsizp = 1, prior_alpha = 1, prior_beta = 0.05,
err_int = c(-10, 10), err_ngrid = 10001, num_batch = 20,
step = 10, alpha, ...)
Arguments
data_x
An (n by p) matrix of discretised data points of functional curves
data_y
A scalar-valued response of length n
data_xnew
A matrix of discretised data points of new functional curve(s)
Xvar
Real-valued predictors. For example, n by 2 matrix
Xvarpred
Real-valued predictors for prediction.
warm
Number of iterations for the burn-in period
M
Number of iterations for the Markov chain Monte Carlo (MCMC)
mutprob
Optimal acceptance rate of the random-walk Metropolis algorithm for sampling the bandwidth in the regression function
errorprob
Optimal acceptance rate of the random-walk Metropolis algorithm for sampling the bandwidth in the kernel-form error density
epsilonprob
Optimal acceptance rate of the random-walk Metropolis algorithm for sampling the bandwidth adjustment factor in the kernel-from error density
mutsizp
Initial step length of the random-walk Metropolis algorithm for sampling the bandwidth in the regression function. Its value will be updated at each iteration to achieve the optimal acceptance rate
errorsizp
Initial step length of the random-walk Metropolis algorithm for sampling the bandwidth in the kernel-form error density. Its value will be updated at each iteration to achieve the optimal acceptance rate
epsilonsizp
Initial step length of the random-walk Metropolis algorithm for sampling the bandwidth adjustment factor in the kernel-form error density. Its value will be updated at each iteration to achieve the optimal acceptance rate
prior_alpha
Hyperparameter of the inverse gamma prior distribution for the squared bandwidths
prior_beta
Hyperparameter of the inverse gamma prior distribution for the squared bandwidths
err_int
Range of the error-density grid for computing the probability density function and cumulative probability density function
err_ngrid
Number of the error-density grid points
num_batch
Number of batches to assess the convergence of the MCMC
step
Thinning parameter. For example, when step=10
, it keeps every 10th iteration of the MCMC output
alpha
The nominal coverage probability of the prediction interval, customarily 95 percent
...
Other arguments used to define semi-metric. For a set of smoothed functional data, the semi-metric based on derivative is suggested. For a set of rough functional data, the semi-metric based on the functional principal component analysis is suggested