## 2 Method
### Model Parameters' Estimations  
It can be said that the objective clustering associated with the FMM technique, identifies subsets of features that could best discriminate the observation crashes, while considering sets of covariates associated for each class. Contrary to frequentist methods, Bayesian methods consider the probability as beliefs. Non informative belief by a prior distribution would be given to an unknown parameter \(\theta\) as \(\pi(\theta)\). After seeing various data observations, based on the [PERSON] theorem, we would have:  
\[\pi(\theta|X_{1},\ldots,X_{1})\sim\mathcal{L}(\theta)\pi(\theta) \tag{13}\]  
where \(\mathcal{L}(\theta)\) is the likelihood function. In summary, in simple words, the process of the MCMC, based on the above equation, would be highlighted in few points as:  
* Express the belief with a probability density (prior distribution) \(\pi(\theta)\), this is without seeing any data. * Now distributions such as negative binomial or logit models would be highlighted to reflect our beliefs about \(x\) given \(\theta\). * After observing data \(\{\ X_{1},\ldots,X_{n}\}\), our beliefs would be updated for estimation of the posterior distribution \(p(\theta|X_{n})\). However, the challenge in the computation of multiparameter problems is, there would be a need to extract inferences about few parameters instead of only a single parameter. Due to difficulty in calculating the integral, the simulation could be used for solving the integral by randomly drawing from the posterior. For instance, for estimating the marginal posterior for \(\theta_{1}\) we would have:  
\[p(\theta_{1}|D_{n})=\int\ldots\int p(\theta_{1},\ldots,\theta_{d}|D)d\theta_{2 },\ldots,d\theta_{d} \tag{14}\]  
simplified distribution, which, based on the law of large number, would be converged to a desired distribution. For instance, consider a complicated function \(h\). We could instead sample from a uniform distribution of U (0, 1) for estimating the integral, and based on the assumption of large number, we could assume the model would converge to the desired integral. Importance sampling is a basic concept of Monte Carlo that addresses the challenge that there is no guarantee that the sampling, likelihood function, is from a known distribution. For instance, consider g is a probability density that we know how to sample from, and \(f\) is the probability density, which we do not know how to sample from, we have:  
\[I=\int h(x)f(x)dx=\int\frac{h(x)f(x)}{g(x)}g(x)d(x)=\mathbb{E}_{g}(Y) \tag{16}\]  
Again, by the law of large number for the above we have \(\hat{I}\to I\). The Gibbs sampling would be used to find the conditional distribution of a parameter, conditioned on all other parameters. The concept is by gathering information and receiving feedbacks from the model, we would refine our belief to get closer to the truth. That follows a Bayes theorem. The knowledge of various explanatory variables would update our beliefs about the status of the crash counts. Thus, by gathering more information and updating the beliefs we can get closer to the truth. The idea behind the Markov chain is that the random samples are generated by a special sequential process. In other words, the next random sample would be generated based on a previous generated value. It should be noted that although each new sample is dependent on the before samples, new samples are not dependent on the ones before the previous. The process with Gibbs sampling could be summarized as follows:  
1. Begin with the starting values. 2. Generate a new proposal by taking the last sample and adding some noise. The noise would be generated from proposal distribution, e.g., normal distribution with a mean of zero and wide precision. 3. Estimate the next samples from the previous values with no rejection. Instead of the accept-reject method, or Metropolis-Hastings, we use Gibbs sampling, which is based on \(\theta_{2}^{(j)}\sim p(\theta_{2}|\theta_{1}^{(j)})\). This would be estimated with the assumed distribution.