Internal function for the package EntropyMCMC, computes the acceptance ratio required in the definition of any Hastings-Metropolis algorithm.
accept_ratio(x, y, target, q_pdf, f_param, q_param, symmetric = FALSE)The current position.
The next (proposal) position.
The target density for which the MCMC algorithm is defined;
may be given only up to a multiplicative constant for most MCMC.
Target must be a function such as the multidimensional gaussian
target_norm(x,param).
The density of the proposal.
A list holding all the necessary target parameters, consistent with the target definition.
A list holding all the necessary parameters
for the proposal density of the MCMC algorithm mcmc_algo.
If TRUE, the proposal q_pdf is symmetric which simplifies the acceptance ratio compuatation
accept_ratio returns a real value alpha, which indicates the computed value of the current accept_ratio.
The accept_ratio is used to decide whether to accept or reject a candidate
\(y\). The acceptance ratio indicates how probable the new proposed candidate is with respect to the current candidate \(x\), according to the distribution target.