## 2 Bayesian Functional Mapping
### Parameter Estimation and Algorithm
However, it is straightforward to derive either full conditional posterior distributions for some parameters, or the explicit expressions that are proportional to the corresponding full conditional posterior distributions for other parameters, i.e.,  
\[\pi(\mathbf{\Theta}_{j}|\mathbf{y},\mathbf{\Theta}_{-j},\mathbf{ \Sigma},\mathbf{Q},\lambda) \tag{8}\] \[\propto \pi(\mathbf{y}|\mathbf{\Theta},\mathbf{\Sigma},\mathbf{Q},\lambda )\cdot\pi(\mathbf{\Theta}_{j})\] \[\propto \exp\left\{-\frac{1}{2}\sum_{i=1}^{n_{j}}\left[(\mathbf{y}_{ij}- g(\mathbf{t}|\mathbf{\Theta}_{j}))^{\prime}\mathbf{\Sigma}^{-1}(\mathbf{y}_{ij}-g (\mathbf{t}|\mathbf{\Theta}_{j}))\right]-\frac{1}{2}(\mathbf{\Theta}_{j}-\eta )^{\prime}\Lambda^{-1}(\mathbf{\Theta}_{j}-\eta)\right\}\]  
and  
\[\pi(\mathbf{\Sigma}^{-1}|\mathbf{y},\mathbf{\Theta},\mathbf{Q},\lambda) \tag{9}\] \[= \pi(\mathbf{y}|\mathbf{\Theta},\mathbf{\Sigma}^{-1},\mathbf{Q}, \lambda)\cdot\pi(\mathbf{\Sigma}^{-1})\] \[\propto |\mathbf{\Sigma}^{-1}|^{\frac{n+\rho+T+1}{2}}\cdot\exp\left\{- \frac{1}{2}\mbox{\it tr}\left[\mathbf{R}^{-1}\,\mathbf{\Sigma}^{-1}+\sum_{j=0 }^{2}\sum_{i=1}^{n_{j}}(\mathbf{y}_{ij}-g(\mathbf{t}|\mathbf{\Theta}_{j}))( \mathbf{y}_{ij}-g(\mathbf{t}|\mathbf{\Theta}_{j}))^{\prime}\right]\right\}\] \[\backsim \mbox{\it Wi}(\mathbf{D}^{-1},n+\rho) \tag{10}\]  
where \(\mathbf{\Theta}_{-j}=\{\mathbf{\Theta}_{j^{\prime}}:j^{\prime}=0,1,2,j^{\prime }\
eq j\}\), \(\mathbf{y}_{ij}\) contains the observations from those individuals with genotype \(j\), and \(\mathbf{D}=\mathbf{R}^{-1}+\sum_{j=0}^{2}\sum_{i=1}^{n_{j}}(\mathbf{y}_{ij}-g( \mathbf{t}|\mathbf{\Theta}_{j}))(\mathbf{y}_{ij}-g(\mathbf{t}|\mathbf{\Theta} _{j}))^{\prime}\). Algorithm implementation  
Within the Bayesian framework, with the explicit expressions described in the preceding section, a Markov chain Monte Carlo (MCMC) technique can be used to draw samples from the joint posterior distributions of unknown parameters (6). We will use a hybrid scheme of Gibbs sampler and Metroplolis-Hastings (M-H) algorithm [27, 28]. In particular, Gibbs sampling steps update \(\mathbf{\Sigma}^{-1}\), while the M-H algorithm updates \(\mathbf{\Theta}_{j}\) and the QTL position. After generating a random sequence of states \((\lambda^{0},\mathbf{Q}^{0},\mathbf{\Theta}^{0},\mathbf{\Sigma}^{0})\), \((\lambda^{1},\mathbf{Q}^{1},\mathbf{\Theta}^{1},\mathbf{\Sigma}^{1})\), \(\cdots\), \((\lambda^{N},\mathbf{Q}^{N},\mathbf{\Theta}^{N},\mathbf{\Sigma}^{N})\), the final MCMC samples are collected, from which we are able to make the inference about the unknown parameters. The construction of the Markov chain process was described in Appendix A.  
Estimation issues  
For parameters \(\lambda\) and \(\mathbf{\Theta}\), the empirical means of their marginal posteriors are the Bayesian estimators. As justified by [PERSON] [28], for any unknown parametric family \(f\), which is a square integrable with respect to the stationary distribution \(\pi\), we have:  
\[\bar{f}_{N}=\frac{1}{N}\sum_{k=1}^{N}f(\lambda^{(k)},\mathbf{\Theta}^{(k)}, \mathbf{Q}^{(k)},\mathbf{\Sigma}^{(k)})\to E_{\pi}[f(\lambda,\mathbf{\Theta}, \mathbf{Q},\mathbf{\Sigma}\,|\,\mathbf{y})\,], \tag{11}\]  
under the assumption that \((\lambda^{(k)},\mathbf{\Theta}^{(k)},\mathbf{Q}^{(k)},\mathbf{\Sigma}^{(k)})\) are the samples from the Markov chain. In other words, the empirical averages of the corresponding MCMC samples may be regarded as the consistent estimators for the unknown parameters. The marginal posterior densities of these parameters are determined from the kernel density estimator [29], since the closed form of their full conditional posteriors are not available. For example, the histogram kernel density estimator for \(\lambda\) is given by:  
\[\pi(\lambda,\mathbf{\Theta},\mathbf{\Sigma})=\pi(\lambda)\cdot\pi(\Sigma) \cdot\prod_{j=0}^{2}\pi(\mathbf{\Theta}_{j}). \tag{7}\]0  
A second important estimation issue is to obtain the confidence intervals for the unknowns.